home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 24 / Amiga Format AFCD24 (Feb 1998, Issue 108).iso / -in_the_mag- / emulation / macos / cpu68000.cpt.hqx / CPU68000 / CPU / cpu0.c next >
C/C++ Source or Header  |  1997-06-16  |  91KB  |  3,058 lines

  1. #include "sysconfig.h"
  2. #include "sysdeps.h"
  3. #include "config.h"
  4. #include "options.h"
  5. #include "machdep/m68k.h"
  6. #include "my_memory.h"
  7. #include "custom.h"
  8. #include "readcpu.h"
  9. #include "newcpu.h"
  10. #include "compiler.h"
  11. #include "cputbl.h"
  12. #if !defined (MEMFUNCS_DIRECT_REQUESTED) || defined (DIRECT_MEMFUNCS_SUCCESSFUL)
  13. void REGPARAM2 CPU_OP_NAME(_0)(uae_u32 opcode) /* OR */
  14. {
  15.     uae_u32 dstreg = opcode & 7;
  16. {{    uae_s8 src = nextibyte();
  17. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  18.     src |= dst;
  19.     VFLG = CFLG = 0;
  20.     ZFLG = ((uae_s8)(src)) == 0;
  21.     NFLG = ((uae_s8)(src)) < 0;
  22.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((src) & 0xff);
  23. }}}}
  24. void REGPARAM2 CPU_OP_NAME(_10)(uae_u32 opcode) /* OR */
  25. {
  26.     uae_u32 dstreg = opcode & 7;
  27. {{    uae_s8 src = nextibyte();
  28. {    uaecptr dsta = m68k_areg(regs, dstreg);
  29.     uae_s8 dst = get_byte(dsta);
  30.     src |= dst;
  31.     VFLG = CFLG = 0;
  32.     ZFLG = ((uae_s8)(src)) == 0;
  33.     NFLG = ((uae_s8)(src)) < 0;
  34.     put_byte(dsta,src);
  35. }}}}
  36. void REGPARAM2 CPU_OP_NAME(_18)(uae_u32 opcode) /* OR */
  37. {
  38.     uae_u32 dstreg = opcode & 7;
  39. {{    uae_s8 src = nextibyte();
  40. {    uaecptr dsta = m68k_areg(regs, dstreg);
  41.     uae_s8 dst = get_byte(dsta);
  42. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  43.     src |= dst;
  44.     VFLG = CFLG = 0;
  45.     ZFLG = ((uae_s8)(src)) == 0;
  46.     NFLG = ((uae_s8)(src)) < 0;
  47.     put_byte(dsta,src);
  48. }}}}}
  49. void REGPARAM2 CPU_OP_NAME(_20)(uae_u32 opcode) /* OR */
  50. {
  51.     uae_u32 dstreg = opcode & 7;
  52. {{    uae_s8 src = nextibyte();
  53. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  54. {    uaecptr dsta = m68k_areg(regs, dstreg);
  55.     uae_s8 dst = get_byte(dsta);
  56.     src |= dst;
  57.     VFLG = CFLG = 0;
  58.     ZFLG = ((uae_s8)(src)) == 0;
  59.     NFLG = ((uae_s8)(src)) < 0;
  60.     put_byte(dsta,src);
  61. }}}}}
  62. void REGPARAM2 CPU_OP_NAME(_28)(uae_u32 opcode) /* OR */
  63. {
  64.     uae_u32 dstreg = opcode & 7;
  65. {{    uae_s8 src = nextibyte();
  66. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  67.     uae_s8 dst = get_byte(dsta);
  68.     src |= dst;
  69.     VFLG = CFLG = 0;
  70.     ZFLG = ((uae_s8)(src)) == 0;
  71.     NFLG = ((uae_s8)(src)) < 0;
  72.     put_byte(dsta,src);
  73. }}}}
  74. void REGPARAM2 CPU_OP_NAME(_30)(uae_u32 opcode) /* OR */
  75. {
  76.     uae_u32 dstreg = opcode & 7;
  77. {{    uae_s8 src = nextibyte();
  78. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  79. {    uae_s8 dst = get_byte(dsta);
  80.     src |= dst;
  81.     VFLG = CFLG = 0;
  82.     ZFLG = ((uae_s8)(src)) == 0;
  83.     NFLG = ((uae_s8)(src)) < 0;
  84.     put_byte(dsta,src);
  85. }}}}}
  86. void REGPARAM2 CPU_OP_NAME(_38)(uae_u32 opcode) /* OR */
  87. {
  88. {{    uae_s8 src = nextibyte();
  89. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  90.     uae_s8 dst = get_byte(dsta);
  91.     src |= dst;
  92.     VFLG = CFLG = 0;
  93.     ZFLG = ((uae_s8)(src)) == 0;
  94.     NFLG = ((uae_s8)(src)) < 0;
  95.     put_byte(dsta,src);
  96. }}}}
  97. void REGPARAM2 CPU_OP_NAME(_39)(uae_u32 opcode) /* OR */
  98. {
  99. {{    uae_s8 src = nextibyte();
  100. {    uaecptr dsta = nextilong();
  101.     uae_s8 dst = get_byte(dsta);
  102.     src |= dst;
  103.     VFLG = CFLG = 0;
  104.     ZFLG = ((uae_s8)(src)) == 0;
  105.     NFLG = ((uae_s8)(src)) < 0;
  106.     put_byte(dsta,src);
  107. }}}}
  108. void REGPARAM2 CPU_OP_NAME(_3c)(uae_u32 opcode) /* ORSR */
  109. {
  110. {    MakeSR();
  111. {    uae_s16 src = nextiword();
  112.     src &= 0xFF;
  113.     regs.sr |= src;
  114.     MakeFromSR();
  115. }}}
  116. void REGPARAM2 CPU_OP_NAME(_40)(uae_u32 opcode) /* OR */
  117. {
  118.     uae_u32 dstreg = opcode & 7;
  119. {{    uae_s16 src = nextiword();
  120. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  121.     src |= dst;
  122.     VFLG = CFLG = 0;
  123.     ZFLG = ((uae_s16)(src)) == 0;
  124.     NFLG = ((uae_s16)(src)) < 0;
  125.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((src) & 0xffff);
  126. }}}}
  127. void REGPARAM2 CPU_OP_NAME(_50)(uae_u32 opcode) /* OR */
  128. {
  129.     uae_u32 dstreg = opcode & 7;
  130. {{    uae_s16 src = nextiword();
  131. {    uaecptr dsta = m68k_areg(regs, dstreg);
  132.     uae_s16 dst = get_word(dsta);
  133.     src |= dst;
  134.     VFLG = CFLG = 0;
  135.     ZFLG = ((uae_s16)(src)) == 0;
  136.     NFLG = ((uae_s16)(src)) < 0;
  137.     put_word(dsta,src);
  138. }}}}
  139. void REGPARAM2 CPU_OP_NAME(_58)(uae_u32 opcode) /* OR */
  140. {
  141.     uae_u32 dstreg = opcode & 7;
  142. {{    uae_s16 src = nextiword();
  143. {    uaecptr dsta = m68k_areg(regs, dstreg);
  144.     uae_s16 dst = get_word(dsta);
  145. {    m68k_areg(regs, dstreg) += 2;
  146.     src |= dst;
  147.     VFLG = CFLG = 0;
  148.     ZFLG = ((uae_s16)(src)) == 0;
  149.     NFLG = ((uae_s16)(src)) < 0;
  150.     put_word(dsta,src);
  151. }}}}}
  152. void REGPARAM2 CPU_OP_NAME(_60)(uae_u32 opcode) /* OR */
  153. {
  154.     uae_u32 dstreg = opcode & 7;
  155. {{    uae_s16 src = nextiword();
  156. {    m68k_areg(regs, dstreg) -= 2;
  157. {    uaecptr dsta = m68k_areg(regs, dstreg);
  158.     uae_s16 dst = get_word(dsta);
  159.     src |= dst;
  160.     VFLG = CFLG = 0;
  161.     ZFLG = ((uae_s16)(src)) == 0;
  162.     NFLG = ((uae_s16)(src)) < 0;
  163.     put_word(dsta,src);
  164. }}}}}
  165. void REGPARAM2 CPU_OP_NAME(_68)(uae_u32 opcode) /* OR */
  166. {
  167.     uae_u32 dstreg = opcode & 7;
  168. {{    uae_s16 src = nextiword();
  169. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  170.     uae_s16 dst = get_word(dsta);
  171.     src |= dst;
  172.     VFLG = CFLG = 0;
  173.     ZFLG = ((uae_s16)(src)) == 0;
  174.     NFLG = ((uae_s16)(src)) < 0;
  175.     put_word(dsta,src);
  176. }}}}
  177. void REGPARAM2 CPU_OP_NAME(_70)(uae_u32 opcode) /* OR */
  178. {
  179.     uae_u32 dstreg = opcode & 7;
  180. {{    uae_s16 src = nextiword();
  181. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  182. {    uae_s16 dst = get_word(dsta);
  183.     src |= dst;
  184.     VFLG = CFLG = 0;
  185.     ZFLG = ((uae_s16)(src)) == 0;
  186.     NFLG = ((uae_s16)(src)) < 0;
  187.     put_word(dsta,src);
  188. }}}}}
  189. void REGPARAM2 CPU_OP_NAME(_78)(uae_u32 opcode) /* OR */
  190. {
  191. {{    uae_s16 src = nextiword();
  192. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  193.     uae_s16 dst = get_word(dsta);
  194.     src |= dst;
  195.     VFLG = CFLG = 0;
  196.     ZFLG = ((uae_s16)(src)) == 0;
  197.     NFLG = ((uae_s16)(src)) < 0;
  198.     put_word(dsta,src);
  199. }}}}
  200. void REGPARAM2 CPU_OP_NAME(_79)(uae_u32 opcode) /* OR */
  201. {
  202. {{    uae_s16 src = nextiword();
  203. {    uaecptr dsta = nextilong();
  204.     uae_s16 dst = get_word(dsta);
  205.     src |= dst;
  206.     VFLG = CFLG = 0;
  207.     ZFLG = ((uae_s16)(src)) == 0;
  208.     NFLG = ((uae_s16)(src)) < 0;
  209.     put_word(dsta,src);
  210. }}}}
  211. void REGPARAM2 CPU_OP_NAME(_7c)(uae_u32 opcode) /* ORSR */
  212. {
  213. {if (!regs.s) { regs.pc_p -= 2; Exception(8,0); } else
  214. {    MakeSR();
  215. {    uae_s16 src = nextiword();
  216.     regs.sr |= src;
  217.     MakeFromSR();
  218. }}}}
  219. void REGPARAM2 CPU_OP_NAME(_80)(uae_u32 opcode) /* OR */
  220. {
  221.     uae_u32 dstreg = opcode & 7;
  222. {{    uae_s32 src = nextilong();
  223. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  224.     src |= dst;
  225.     VFLG = CFLG = 0;
  226.     ZFLG = ((uae_s32)(src)) == 0;
  227.     NFLG = ((uae_s32)(src)) < 0;
  228.     m68k_dreg(regs, dstreg) = (src);
  229. }}}}
  230. void REGPARAM2 CPU_OP_NAME(_90)(uae_u32 opcode) /* OR */
  231. {
  232.     uae_u32 dstreg = opcode & 7;
  233. {{    uae_s32 src = nextilong();
  234. {    uaecptr dsta = m68k_areg(regs, dstreg);
  235.     uae_s32 dst = get_long(dsta);
  236.     src |= dst;
  237.     VFLG = CFLG = 0;
  238.     ZFLG = ((uae_s32)(src)) == 0;
  239.     NFLG = ((uae_s32)(src)) < 0;
  240.     put_long(dsta,src);
  241. }}}}
  242. void REGPARAM2 CPU_OP_NAME(_98)(uae_u32 opcode) /* OR */
  243. {
  244.     uae_u32 dstreg = opcode & 7;
  245. {{    uae_s32 src = nextilong();
  246. {    uaecptr dsta = m68k_areg(regs, dstreg);
  247.     uae_s32 dst = get_long(dsta);
  248. {    m68k_areg(regs, dstreg) += 4;
  249.     src |= dst;
  250.     VFLG = CFLG = 0;
  251.     ZFLG = ((uae_s32)(src)) == 0;
  252.     NFLG = ((uae_s32)(src)) < 0;
  253.     put_long(dsta,src);
  254. }}}}}
  255. void REGPARAM2 CPU_OP_NAME(_a0)(uae_u32 opcode) /* OR */
  256. {
  257.     uae_u32 dstreg = opcode & 7;
  258. {{    uae_s32 src = nextilong();
  259. {    m68k_areg(regs, dstreg) -= 4;
  260. {    uaecptr dsta = m68k_areg(regs, dstreg);
  261.     uae_s32 dst = get_long(dsta);
  262.     src |= dst;
  263.     VFLG = CFLG = 0;
  264.     ZFLG = ((uae_s32)(src)) == 0;
  265.     NFLG = ((uae_s32)(src)) < 0;
  266.     put_long(dsta,src);
  267. }}}}}
  268. void REGPARAM2 CPU_OP_NAME(_a8)(uae_u32 opcode) /* OR */
  269. {
  270.     uae_u32 dstreg = opcode & 7;
  271. {{    uae_s32 src = nextilong();
  272. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  273.     uae_s32 dst = get_long(dsta);
  274.     src |= dst;
  275.     VFLG = CFLG = 0;
  276.     ZFLG = ((uae_s32)(src)) == 0;
  277.     NFLG = ((uae_s32)(src)) < 0;
  278.     put_long(dsta,src);
  279. }}}}
  280. void REGPARAM2 CPU_OP_NAME(_b0)(uae_u32 opcode) /* OR */
  281. {
  282.     uae_u32 dstreg = opcode & 7;
  283. {{    uae_s32 src = nextilong();
  284. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  285. {    uae_s32 dst = get_long(dsta);
  286.     src |= dst;
  287.     VFLG = CFLG = 0;
  288.     ZFLG = ((uae_s32)(src)) == 0;
  289.     NFLG = ((uae_s32)(src)) < 0;
  290.     put_long(dsta,src);
  291. }}}}}
  292. void REGPARAM2 CPU_OP_NAME(_b8)(uae_u32 opcode) /* OR */
  293. {
  294. {{    uae_s32 src = nextilong();
  295. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  296.     uae_s32 dst = get_long(dsta);
  297.     src |= dst;
  298.     VFLG = CFLG = 0;
  299.     ZFLG = ((uae_s32)(src)) == 0;
  300.     NFLG = ((uae_s32)(src)) < 0;
  301.     put_long(dsta,src);
  302. }}}}
  303. void REGPARAM2 CPU_OP_NAME(_b9)(uae_u32 opcode) /* OR */
  304. {
  305. {{    uae_s32 src = nextilong();
  306. {    uaecptr dsta = nextilong();
  307.     uae_s32 dst = get_long(dsta);
  308.     src |= dst;
  309.     VFLG = CFLG = 0;
  310.     ZFLG = ((uae_s32)(src)) == 0;
  311.     NFLG = ((uae_s32)(src)) < 0;
  312.     put_long(dsta,src);
  313. }}}}
  314. void REGPARAM2 CPU_OP_NAME(_100)(uae_u32 opcode) /* BTST */
  315. {
  316.     uae_u32 srcreg = ((opcode >> 9) & 7);
  317.     uae_u32 dstreg = opcode & 7;
  318. {{    uae_s32 src = m68k_dreg(regs, srcreg);
  319. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  320.     src &= 31;
  321.     ZFLG = !(dst & (1 << src));
  322. }}}}
  323. void REGPARAM2 CPU_OP_NAME(_108)(uae_u32 opcode) /* MVPMR */
  324. {
  325.     uae_u32 srcreg = (opcode & 7);
  326.     uae_u32 dstreg = (opcode >> 9) & 7;
  327. {    uaecptr memp = m68k_areg(regs, srcreg) + nextiword();
  328. {    uae_u16 val = (get_byte(memp) << 8) + get_byte(memp + 2);
  329.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((val) & 0xffff);
  330. }}}
  331. void REGPARAM2 CPU_OP_NAME(_110)(uae_u32 opcode) /* BTST */
  332. {
  333.     uae_u32 srcreg = ((opcode >> 9) & 7);
  334.     uae_u32 dstreg = opcode & 7;
  335. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  336. {    uaecptr dsta = m68k_areg(regs, dstreg);
  337.     uae_s8 dst = get_byte(dsta);
  338.     src &= 7;
  339.     ZFLG = !(dst & (1 << src));
  340. }}}}
  341. void REGPARAM2 CPU_OP_NAME(_118)(uae_u32 opcode) /* BTST */
  342. {
  343.     uae_u32 srcreg = ((opcode >> 9) & 7);
  344.     uae_u32 dstreg = opcode & 7;
  345. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  346. {    uaecptr dsta = m68k_areg(regs, dstreg);
  347.     uae_s8 dst = get_byte(dsta);
  348. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  349.     src &= 7;
  350.     ZFLG = !(dst & (1 << src));
  351. }}}}}
  352. void REGPARAM2 CPU_OP_NAME(_120)(uae_u32 opcode) /* BTST */
  353. {
  354.     uae_u32 srcreg = ((opcode >> 9) & 7);
  355.     uae_u32 dstreg = opcode & 7;
  356. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  357. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  358. {    uaecptr dsta = m68k_areg(regs, dstreg);
  359.     uae_s8 dst = get_byte(dsta);
  360.     src &= 7;
  361.     ZFLG = !(dst & (1 << src));
  362. }}}}}
  363. void REGPARAM2 CPU_OP_NAME(_128)(uae_u32 opcode) /* BTST */
  364. {
  365.     uae_u32 srcreg = ((opcode >> 9) & 7);
  366.     uae_u32 dstreg = opcode & 7;
  367. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  368. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  369.     uae_s8 dst = get_byte(dsta);
  370.     src &= 7;
  371.     ZFLG = !(dst & (1 << src));
  372. }}}}
  373. void REGPARAM2 CPU_OP_NAME(_130)(uae_u32 opcode) /* BTST */
  374. {
  375.     uae_u32 srcreg = ((opcode >> 9) & 7);
  376.     uae_u32 dstreg = opcode & 7;
  377. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  378. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  379. {    uae_s8 dst = get_byte(dsta);
  380.     src &= 7;
  381.     ZFLG = !(dst & (1 << src));
  382. }}}}}
  383. void REGPARAM2 CPU_OP_NAME(_138)(uae_u32 opcode) /* BTST */
  384. {
  385.     uae_u32 srcreg = ((opcode >> 9) & 7);
  386. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  387. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  388.     uae_s8 dst = get_byte(dsta);
  389.     src &= 7;
  390.     ZFLG = !(dst & (1 << src));
  391. }}}}
  392. void REGPARAM2 CPU_OP_NAME(_139)(uae_u32 opcode) /* BTST */
  393. {
  394.     uae_u32 srcreg = ((opcode >> 9) & 7);
  395. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  396. {    uaecptr dsta = nextilong();
  397.     uae_s8 dst = get_byte(dsta);
  398.     src &= 7;
  399.     ZFLG = !(dst & (1 << src));
  400. }}}}
  401. void REGPARAM2 CPU_OP_NAME(_13a)(uae_u32 opcode) /* BTST */
  402. {
  403.     uae_u32 srcreg = ((opcode >> 9) & 7);
  404.     uae_u32 dstreg = 2;
  405. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  406. {    uaecptr dsta = m68k_getpc();
  407.     dsta += (uae_s32)(uae_s16)nextiword();
  408. {    uae_s8 dst = get_byte(dsta);
  409.     src &= 7;
  410.     ZFLG = !(dst & (1 << src));
  411. }}}}}
  412. void REGPARAM2 CPU_OP_NAME(_13b)(uae_u32 opcode) /* BTST */
  413. {
  414.     uae_u32 srcreg = ((opcode >> 9) & 7);
  415.     uae_u32 dstreg = 3;
  416. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  417. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  418. {    uae_s8 dst = get_byte(dsta);
  419.     src &= 7;
  420.     ZFLG = !(dst & (1 << src));
  421. }}}}}
  422. void REGPARAM2 CPU_OP_NAME(_13c)(uae_u32 opcode) /* BTST */
  423. {
  424.     uae_u32 srcreg = ((opcode >> 9) & 7);
  425. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  426. {    uae_s8 dst = nextibyte();
  427.     src &= 7;
  428.     ZFLG = !(dst & (1 << src));
  429. }}}}
  430. void REGPARAM2 CPU_OP_NAME(_140)(uae_u32 opcode) /* BCHG */
  431. {
  432.     uae_u32 srcreg = ((opcode >> 9) & 7);
  433.     uae_u32 dstreg = opcode & 7;
  434. {{    uae_s32 src = m68k_dreg(regs, srcreg);
  435. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  436.     src &= 31;
  437.     ZFLG = !(dst & (1 << src));
  438.     dst ^= (1 << src);
  439.     m68k_dreg(regs, dstreg) = (dst);
  440. }}}}
  441. void REGPARAM2 CPU_OP_NAME(_148)(uae_u32 opcode) /* MVPMR */
  442. {
  443.     uae_u32 srcreg = (opcode & 7);
  444.     uae_u32 dstreg = (opcode >> 9) & 7;
  445. {    uaecptr memp = m68k_areg(regs, srcreg) + nextiword();
  446. {    uae_u32 val = (get_byte(memp) << 24) + (get_byte(memp + 2) << 16)
  447.               + (get_byte(memp + 4) << 8) + get_byte(memp + 6);
  448.     m68k_dreg(regs, dstreg) = (val);
  449. }}}
  450. void REGPARAM2 CPU_OP_NAME(_150)(uae_u32 opcode) /* BCHG */
  451. {
  452.     uae_u32 srcreg = ((opcode >> 9) & 7);
  453.     uae_u32 dstreg = opcode & 7;
  454. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  455. {    uaecptr dsta = m68k_areg(regs, dstreg);
  456.     uae_s8 dst = get_byte(dsta);
  457.     src &= 7;
  458.     ZFLG = !(dst & (1 << src));
  459.     dst ^= (1 << src);
  460.     put_byte(dsta,dst);
  461. }}}}
  462. void REGPARAM2 CPU_OP_NAME(_158)(uae_u32 opcode) /* BCHG */
  463. {
  464.     uae_u32 srcreg = ((opcode >> 9) & 7);
  465.     uae_u32 dstreg = opcode & 7;
  466. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  467. {    uaecptr dsta = m68k_areg(regs, dstreg);
  468.     uae_s8 dst = get_byte(dsta);
  469. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  470.     src &= 7;
  471.     ZFLG = !(dst & (1 << src));
  472.     dst ^= (1 << src);
  473.     put_byte(dsta,dst);
  474. }}}}}
  475. void REGPARAM2 CPU_OP_NAME(_160)(uae_u32 opcode) /* BCHG */
  476. {
  477.     uae_u32 srcreg = ((opcode >> 9) & 7);
  478.     uae_u32 dstreg = opcode & 7;
  479. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  480. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  481. {    uaecptr dsta = m68k_areg(regs, dstreg);
  482.     uae_s8 dst = get_byte(dsta);
  483.     src &= 7;
  484.     ZFLG = !(dst & (1 << src));
  485.     dst ^= (1 << src);
  486.     put_byte(dsta,dst);
  487. }}}}}
  488. void REGPARAM2 CPU_OP_NAME(_168)(uae_u32 opcode) /* BCHG */
  489. {
  490.     uae_u32 srcreg = ((opcode >> 9) & 7);
  491.     uae_u32 dstreg = opcode & 7;
  492. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  493. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  494.     uae_s8 dst = get_byte(dsta);
  495.     src &= 7;
  496.     ZFLG = !(dst & (1 << src));
  497.     dst ^= (1 << src);
  498.     put_byte(dsta,dst);
  499. }}}}
  500. void REGPARAM2 CPU_OP_NAME(_170)(uae_u32 opcode) /* BCHG */
  501. {
  502.     uae_u32 srcreg = ((opcode >> 9) & 7);
  503.     uae_u32 dstreg = opcode & 7;
  504. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  505. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  506. {    uae_s8 dst = get_byte(dsta);
  507.     src &= 7;
  508.     ZFLG = !(dst & (1 << src));
  509.     dst ^= (1 << src);
  510.     put_byte(dsta,dst);
  511. }}}}}
  512. void REGPARAM2 CPU_OP_NAME(_178)(uae_u32 opcode) /* BCHG */
  513. {
  514.     uae_u32 srcreg = ((opcode >> 9) & 7);
  515. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  516. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  517.     uae_s8 dst = get_byte(dsta);
  518.     src &= 7;
  519.     ZFLG = !(dst & (1 << src));
  520.     dst ^= (1 << src);
  521.     put_byte(dsta,dst);
  522. }}}}
  523. void REGPARAM2 CPU_OP_NAME(_179)(uae_u32 opcode) /* BCHG */
  524. {
  525.     uae_u32 srcreg = ((opcode >> 9) & 7);
  526. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  527. {    uaecptr dsta = nextilong();
  528.     uae_s8 dst = get_byte(dsta);
  529.     src &= 7;
  530.     ZFLG = !(dst & (1 << src));
  531.     dst ^= (1 << src);
  532.     put_byte(dsta,dst);
  533. }}}}
  534. void REGPARAM2 CPU_OP_NAME(_17a)(uae_u32 opcode) /* BCHG */
  535. {
  536.     uae_u32 srcreg = ((opcode >> 9) & 7);
  537.     uae_u32 dstreg = 2;
  538. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  539. {    uaecptr dsta = m68k_getpc();
  540.     dsta += (uae_s32)(uae_s16)nextiword();
  541. {    uae_s8 dst = get_byte(dsta);
  542.     src &= 7;
  543.     ZFLG = !(dst & (1 << src));
  544.     dst ^= (1 << src);
  545.     put_byte(dsta,dst);
  546. }}}}}
  547. void REGPARAM2 CPU_OP_NAME(_17b)(uae_u32 opcode) /* BCHG */
  548. {
  549.     uae_u32 srcreg = ((opcode >> 9) & 7);
  550.     uae_u32 dstreg = 3;
  551. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  552. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  553. {    uae_s8 dst = get_byte(dsta);
  554.     src &= 7;
  555.     ZFLG = !(dst & (1 << src));
  556.     dst ^= (1 << src);
  557.     put_byte(dsta,dst);
  558. }}}}}
  559. void REGPARAM2 CPU_OP_NAME(_180)(uae_u32 opcode) /* BCLR */
  560. {
  561.     uae_u32 srcreg = ((opcode >> 9) & 7);
  562.     uae_u32 dstreg = opcode & 7;
  563. {{    uae_s32 src = m68k_dreg(regs, srcreg);
  564. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  565.     src &= 31;
  566.     ZFLG = !(dst & (1 << src));
  567.     dst &= ~(1 << src);
  568.     m68k_dreg(regs, dstreg) = (dst);
  569. }}}}
  570. void REGPARAM2 CPU_OP_NAME(_188)(uae_u32 opcode) /* MVPRM */
  571. {
  572.     uae_u32 srcreg = ((opcode >> 9) & 7);
  573.     uae_u32 dstreg = opcode & 7;
  574. {{    uae_s16 src = m68k_dreg(regs, srcreg);
  575.     uaecptr memp = m68k_areg(regs, dstreg) + nextiword();
  576.     put_byte(memp, src >> 8); put_byte(memp + 2, src);
  577. }}}
  578. void REGPARAM2 CPU_OP_NAME(_190)(uae_u32 opcode) /* BCLR */
  579. {
  580.     uae_u32 srcreg = ((opcode >> 9) & 7);
  581.     uae_u32 dstreg = opcode & 7;
  582. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  583. {    uaecptr dsta = m68k_areg(regs, dstreg);
  584.     uae_s8 dst = get_byte(dsta);
  585.     src &= 7;
  586.     ZFLG = !(dst & (1 << src));
  587.     dst &= ~(1 << src);
  588.     put_byte(dsta,dst);
  589. }}}}
  590. void REGPARAM2 CPU_OP_NAME(_198)(uae_u32 opcode) /* BCLR */
  591. {
  592.     uae_u32 srcreg = ((opcode >> 9) & 7);
  593.     uae_u32 dstreg = opcode & 7;
  594. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  595. {    uaecptr dsta = m68k_areg(regs, dstreg);
  596.     uae_s8 dst = get_byte(dsta);
  597. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  598.     src &= 7;
  599.     ZFLG = !(dst & (1 << src));
  600.     dst &= ~(1 << src);
  601.     put_byte(dsta,dst);
  602. }}}}}
  603. void REGPARAM2 CPU_OP_NAME(_1a0)(uae_u32 opcode) /* BCLR */
  604. {
  605.     uae_u32 srcreg = ((opcode >> 9) & 7);
  606.     uae_u32 dstreg = opcode & 7;
  607. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  608. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  609. {    uaecptr dsta = m68k_areg(regs, dstreg);
  610.     uae_s8 dst = get_byte(dsta);
  611.     src &= 7;
  612.     ZFLG = !(dst & (1 << src));
  613.     dst &= ~(1 << src);
  614.     put_byte(dsta,dst);
  615. }}}}}
  616. void REGPARAM2 CPU_OP_NAME(_1a8)(uae_u32 opcode) /* BCLR */
  617. {
  618.     uae_u32 srcreg = ((opcode >> 9) & 7);
  619.     uae_u32 dstreg = opcode & 7;
  620. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  621. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  622.     uae_s8 dst = get_byte(dsta);
  623.     src &= 7;
  624.     ZFLG = !(dst & (1 << src));
  625.     dst &= ~(1 << src);
  626.     put_byte(dsta,dst);
  627. }}}}
  628. void REGPARAM2 CPU_OP_NAME(_1b0)(uae_u32 opcode) /* BCLR */
  629. {
  630.     uae_u32 srcreg = ((opcode >> 9) & 7);
  631.     uae_u32 dstreg = opcode & 7;
  632. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  633. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  634. {    uae_s8 dst = get_byte(dsta);
  635.     src &= 7;
  636.     ZFLG = !(dst & (1 << src));
  637.     dst &= ~(1 << src);
  638.     put_byte(dsta,dst);
  639. }}}}}
  640. void REGPARAM2 CPU_OP_NAME(_1b8)(uae_u32 opcode) /* BCLR */
  641. {
  642.     uae_u32 srcreg = ((opcode >> 9) & 7);
  643. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  644. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  645.     uae_s8 dst = get_byte(dsta);
  646.     src &= 7;
  647.     ZFLG = !(dst & (1 << src));
  648.     dst &= ~(1 << src);
  649.     put_byte(dsta,dst);
  650. }}}}
  651. void REGPARAM2 CPU_OP_NAME(_1b9)(uae_u32 opcode) /* BCLR */
  652. {
  653.     uae_u32 srcreg = ((opcode >> 9) & 7);
  654. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  655. {    uaecptr dsta = nextilong();
  656.     uae_s8 dst = get_byte(dsta);
  657.     src &= 7;
  658.     ZFLG = !(dst & (1 << src));
  659.     dst &= ~(1 << src);
  660.     put_byte(dsta,dst);
  661. }}}}
  662. void REGPARAM2 CPU_OP_NAME(_1ba)(uae_u32 opcode) /* BCLR */
  663. {
  664.     uae_u32 srcreg = ((opcode >> 9) & 7);
  665.     uae_u32 dstreg = 2;
  666. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  667. {    uaecptr dsta = m68k_getpc();
  668.     dsta += (uae_s32)(uae_s16)nextiword();
  669. {    uae_s8 dst = get_byte(dsta);
  670.     src &= 7;
  671.     ZFLG = !(dst & (1 << src));
  672.     dst &= ~(1 << src);
  673.     put_byte(dsta,dst);
  674. }}}}}
  675. void REGPARAM2 CPU_OP_NAME(_1bb)(uae_u32 opcode) /* BCLR */
  676. {
  677.     uae_u32 srcreg = ((opcode >> 9) & 7);
  678.     uae_u32 dstreg = 3;
  679. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  680. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  681. {    uae_s8 dst = get_byte(dsta);
  682.     src &= 7;
  683.     ZFLG = !(dst & (1 << src));
  684.     dst &= ~(1 << src);
  685.     put_byte(dsta,dst);
  686. }}}}}
  687. void REGPARAM2 CPU_OP_NAME(_1c0)(uae_u32 opcode) /* BSET */
  688. {
  689.     uae_u32 srcreg = ((opcode >> 9) & 7);
  690.     uae_u32 dstreg = opcode & 7;
  691. {{    uae_s32 src = m68k_dreg(regs, srcreg);
  692. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  693.     src &= 31;
  694.     ZFLG = !(dst & (1 << src));
  695.     dst |= (1 << src);
  696.     m68k_dreg(regs, dstreg) = (dst);
  697. }}}}
  698. void REGPARAM2 CPU_OP_NAME(_1c8)(uae_u32 opcode) /* MVPRM */
  699. {
  700.     uae_u32 srcreg = ((opcode >> 9) & 7);
  701.     uae_u32 dstreg = opcode & 7;
  702. {{    uae_s32 src = m68k_dreg(regs, srcreg);
  703.     uaecptr memp = m68k_areg(regs, dstreg) + nextiword();
  704.     put_byte(memp, src >> 24); put_byte(memp + 2, src >> 16);
  705.     put_byte(memp + 4, src >> 8); put_byte(memp + 6, src);
  706. }}}
  707. void REGPARAM2 CPU_OP_NAME(_1d0)(uae_u32 opcode) /* BSET */
  708. {
  709.     uae_u32 srcreg = ((opcode >> 9) & 7);
  710.     uae_u32 dstreg = opcode & 7;
  711. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  712. {    uaecptr dsta = m68k_areg(regs, dstreg);
  713.     uae_s8 dst = get_byte(dsta);
  714.     src &= 7;
  715.     ZFLG = !(dst & (1 << src));
  716.     dst |= (1 << src);
  717.     put_byte(dsta,dst);
  718. }}}}
  719. void REGPARAM2 CPU_OP_NAME(_1d8)(uae_u32 opcode) /* BSET */
  720. {
  721.     uae_u32 srcreg = ((opcode >> 9) & 7);
  722.     uae_u32 dstreg = opcode & 7;
  723. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  724. {    uaecptr dsta = m68k_areg(regs, dstreg);
  725.     uae_s8 dst = get_byte(dsta);
  726. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  727.     src &= 7;
  728.     ZFLG = !(dst & (1 << src));
  729.     dst |= (1 << src);
  730.     put_byte(dsta,dst);
  731. }}}}}
  732. void REGPARAM2 CPU_OP_NAME(_1e0)(uae_u32 opcode) /* BSET */
  733. {
  734.     uae_u32 srcreg = ((opcode >> 9) & 7);
  735.     uae_u32 dstreg = opcode & 7;
  736. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  737. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  738. {    uaecptr dsta = m68k_areg(regs, dstreg);
  739.     uae_s8 dst = get_byte(dsta);
  740.     src &= 7;
  741.     ZFLG = !(dst & (1 << src));
  742.     dst |= (1 << src);
  743.     put_byte(dsta,dst);
  744. }}}}}
  745. void REGPARAM2 CPU_OP_NAME(_1e8)(uae_u32 opcode) /* BSET */
  746. {
  747.     uae_u32 srcreg = ((opcode >> 9) & 7);
  748.     uae_u32 dstreg = opcode & 7;
  749. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  750. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  751.     uae_s8 dst = get_byte(dsta);
  752.     src &= 7;
  753.     ZFLG = !(dst & (1 << src));
  754.     dst |= (1 << src);
  755.     put_byte(dsta,dst);
  756. }}}}
  757. void REGPARAM2 CPU_OP_NAME(_1f0)(uae_u32 opcode) /* BSET */
  758. {
  759.     uae_u32 srcreg = ((opcode >> 9) & 7);
  760.     uae_u32 dstreg = opcode & 7;
  761. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  762. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  763. {    uae_s8 dst = get_byte(dsta);
  764.     src &= 7;
  765.     ZFLG = !(dst & (1 << src));
  766.     dst |= (1 << src);
  767.     put_byte(dsta,dst);
  768. }}}}}
  769. void REGPARAM2 CPU_OP_NAME(_1f8)(uae_u32 opcode) /* BSET */
  770. {
  771.     uae_u32 srcreg = ((opcode >> 9) & 7);
  772. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  773. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  774.     uae_s8 dst = get_byte(dsta);
  775.     src &= 7;
  776.     ZFLG = !(dst & (1 << src));
  777.     dst |= (1 << src);
  778.     put_byte(dsta,dst);
  779. }}}}
  780. void REGPARAM2 CPU_OP_NAME(_1f9)(uae_u32 opcode) /* BSET */
  781. {
  782.     uae_u32 srcreg = ((opcode >> 9) & 7);
  783. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  784. {    uaecptr dsta = nextilong();
  785.     uae_s8 dst = get_byte(dsta);
  786.     src &= 7;
  787.     ZFLG = !(dst & (1 << src));
  788.     dst |= (1 << src);
  789.     put_byte(dsta,dst);
  790. }}}}
  791. void REGPARAM2 CPU_OP_NAME(_1fa)(uae_u32 opcode) /* BSET */
  792. {
  793.     uae_u32 srcreg = ((opcode >> 9) & 7);
  794.     uae_u32 dstreg = 2;
  795. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  796. {    uaecptr dsta = m68k_getpc();
  797.     dsta += (uae_s32)(uae_s16)nextiword();
  798. {    uae_s8 dst = get_byte(dsta);
  799.     src &= 7;
  800.     ZFLG = !(dst & (1 << src));
  801.     dst |= (1 << src);
  802.     put_byte(dsta,dst);
  803. }}}}}
  804. void REGPARAM2 CPU_OP_NAME(_1fb)(uae_u32 opcode) /* BSET */
  805. {
  806.     uae_u32 srcreg = ((opcode >> 9) & 7);
  807.     uae_u32 dstreg = 3;
  808. {{    uae_s8 src = m68k_dreg(regs, srcreg);
  809. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  810. {    uae_s8 dst = get_byte(dsta);
  811.     src &= 7;
  812.     ZFLG = !(dst & (1 << src));
  813.     dst |= (1 << src);
  814.     put_byte(dsta,dst);
  815. }}}}}
  816. void REGPARAM2 CPU_OP_NAME(_200)(uae_u32 opcode) /* AND */
  817. {
  818.     uae_u32 dstreg = opcode & 7;
  819. {{    uae_s8 src = nextibyte();
  820. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  821.     src &= dst;
  822.     VFLG = CFLG = 0;
  823.     ZFLG = ((uae_s8)(src)) == 0;
  824.     NFLG = ((uae_s8)(src)) < 0;
  825.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((src) & 0xff);
  826. }}}}
  827. void REGPARAM2 CPU_OP_NAME(_210)(uae_u32 opcode) /* AND */
  828. {
  829.     uae_u32 dstreg = opcode & 7;
  830. {{    uae_s8 src = nextibyte();
  831. {    uaecptr dsta = m68k_areg(regs, dstreg);
  832.     uae_s8 dst = get_byte(dsta);
  833.     src &= dst;
  834.     VFLG = CFLG = 0;
  835.     ZFLG = ((uae_s8)(src)) == 0;
  836.     NFLG = ((uae_s8)(src)) < 0;
  837.     put_byte(dsta,src);
  838. }}}}
  839. void REGPARAM2 CPU_OP_NAME(_218)(uae_u32 opcode) /* AND */
  840. {
  841.     uae_u32 dstreg = opcode & 7;
  842. {{    uae_s8 src = nextibyte();
  843. {    uaecptr dsta = m68k_areg(regs, dstreg);
  844.     uae_s8 dst = get_byte(dsta);
  845. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  846.     src &= dst;
  847.     VFLG = CFLG = 0;
  848.     ZFLG = ((uae_s8)(src)) == 0;
  849.     NFLG = ((uae_s8)(src)) < 0;
  850.     put_byte(dsta,src);
  851. }}}}}
  852. void REGPARAM2 CPU_OP_NAME(_220)(uae_u32 opcode) /* AND */
  853. {
  854.     uae_u32 dstreg = opcode & 7;
  855. {{    uae_s8 src = nextibyte();
  856. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  857. {    uaecptr dsta = m68k_areg(regs, dstreg);
  858.     uae_s8 dst = get_byte(dsta);
  859.     src &= dst;
  860.     VFLG = CFLG = 0;
  861.     ZFLG = ((uae_s8)(src)) == 0;
  862.     NFLG = ((uae_s8)(src)) < 0;
  863.     put_byte(dsta,src);
  864. }}}}}
  865. void REGPARAM2 CPU_OP_NAME(_228)(uae_u32 opcode) /* AND */
  866. {
  867.     uae_u32 dstreg = opcode & 7;
  868. {{    uae_s8 src = nextibyte();
  869. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  870.     uae_s8 dst = get_byte(dsta);
  871.     src &= dst;
  872.     VFLG = CFLG = 0;
  873.     ZFLG = ((uae_s8)(src)) == 0;
  874.     NFLG = ((uae_s8)(src)) < 0;
  875.     put_byte(dsta,src);
  876. }}}}
  877. void REGPARAM2 CPU_OP_NAME(_230)(uae_u32 opcode) /* AND */
  878. {
  879.     uae_u32 dstreg = opcode & 7;
  880. {{    uae_s8 src = nextibyte();
  881. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  882. {    uae_s8 dst = get_byte(dsta);
  883.     src &= dst;
  884.     VFLG = CFLG = 0;
  885.     ZFLG = ((uae_s8)(src)) == 0;
  886.     NFLG = ((uae_s8)(src)) < 0;
  887.     put_byte(dsta,src);
  888. }}}}}
  889. void REGPARAM2 CPU_OP_NAME(_238)(uae_u32 opcode) /* AND */
  890. {
  891. {{    uae_s8 src = nextibyte();
  892. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  893.     uae_s8 dst = get_byte(dsta);
  894.     src &= dst;
  895.     VFLG = CFLG = 0;
  896.     ZFLG = ((uae_s8)(src)) == 0;
  897.     NFLG = ((uae_s8)(src)) < 0;
  898.     put_byte(dsta,src);
  899. }}}}
  900. void REGPARAM2 CPU_OP_NAME(_239)(uae_u32 opcode) /* AND */
  901. {
  902. {{    uae_s8 src = nextibyte();
  903. {    uaecptr dsta = nextilong();
  904.     uae_s8 dst = get_byte(dsta);
  905.     src &= dst;
  906.     VFLG = CFLG = 0;
  907.     ZFLG = ((uae_s8)(src)) == 0;
  908.     NFLG = ((uae_s8)(src)) < 0;
  909.     put_byte(dsta,src);
  910. }}}}
  911. void REGPARAM2 CPU_OP_NAME(_23c)(uae_u32 opcode) /* ANDSR */
  912. {
  913. {    MakeSR();
  914. {    uae_s16 src = nextiword();
  915.     src |= 0xFF00;
  916.     regs.sr &= src;
  917.     MakeFromSR();
  918. }}}
  919. void REGPARAM2 CPU_OP_NAME(_240)(uae_u32 opcode) /* AND */
  920. {
  921.     uae_u32 dstreg = opcode & 7;
  922. {{    uae_s16 src = nextiword();
  923. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  924.     src &= dst;
  925.     VFLG = CFLG = 0;
  926.     ZFLG = ((uae_s16)(src)) == 0;
  927.     NFLG = ((uae_s16)(src)) < 0;
  928.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((src) & 0xffff);
  929. }}}}
  930. void REGPARAM2 CPU_OP_NAME(_250)(uae_u32 opcode) /* AND */
  931. {
  932.     uae_u32 dstreg = opcode & 7;
  933. {{    uae_s16 src = nextiword();
  934. {    uaecptr dsta = m68k_areg(regs, dstreg);
  935.     uae_s16 dst = get_word(dsta);
  936.     src &= dst;
  937.     VFLG = CFLG = 0;
  938.     ZFLG = ((uae_s16)(src)) == 0;
  939.     NFLG = ((uae_s16)(src)) < 0;
  940.     put_word(dsta,src);
  941. }}}}
  942. void REGPARAM2 CPU_OP_NAME(_258)(uae_u32 opcode) /* AND */
  943. {
  944.     uae_u32 dstreg = opcode & 7;
  945. {{    uae_s16 src = nextiword();
  946. {    uaecptr dsta = m68k_areg(regs, dstreg);
  947.     uae_s16 dst = get_word(dsta);
  948. {    m68k_areg(regs, dstreg) += 2;
  949.     src &= dst;
  950.     VFLG = CFLG = 0;
  951.     ZFLG = ((uae_s16)(src)) == 0;
  952.     NFLG = ((uae_s16)(src)) < 0;
  953.     put_word(dsta,src);
  954. }}}}}
  955. void REGPARAM2 CPU_OP_NAME(_260)(uae_u32 opcode) /* AND */
  956. {
  957.     uae_u32 dstreg = opcode & 7;
  958. {{    uae_s16 src = nextiword();
  959. {    m68k_areg(regs, dstreg) -= 2;
  960. {    uaecptr dsta = m68k_areg(regs, dstreg);
  961.     uae_s16 dst = get_word(dsta);
  962.     src &= dst;
  963.     VFLG = CFLG = 0;
  964.     ZFLG = ((uae_s16)(src)) == 0;
  965.     NFLG = ((uae_s16)(src)) < 0;
  966.     put_word(dsta,src);
  967. }}}}}
  968. void REGPARAM2 CPU_OP_NAME(_268)(uae_u32 opcode) /* AND */
  969. {
  970.     uae_u32 dstreg = opcode & 7;
  971. {{    uae_s16 src = nextiword();
  972. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  973.     uae_s16 dst = get_word(dsta);
  974.     src &= dst;
  975.     VFLG = CFLG = 0;
  976.     ZFLG = ((uae_s16)(src)) == 0;
  977.     NFLG = ((uae_s16)(src)) < 0;
  978.     put_word(dsta,src);
  979. }}}}
  980. void REGPARAM2 CPU_OP_NAME(_270)(uae_u32 opcode) /* AND */
  981. {
  982.     uae_u32 dstreg = opcode & 7;
  983. {{    uae_s16 src = nextiword();
  984. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  985. {    uae_s16 dst = get_word(dsta);
  986.     src &= dst;
  987.     VFLG = CFLG = 0;
  988.     ZFLG = ((uae_s16)(src)) == 0;
  989.     NFLG = ((uae_s16)(src)) < 0;
  990.     put_word(dsta,src);
  991. }}}}}
  992. void REGPARAM2 CPU_OP_NAME(_278)(uae_u32 opcode) /* AND */
  993. {
  994. {{    uae_s16 src = nextiword();
  995. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  996.     uae_s16 dst = get_word(dsta);
  997.     src &= dst;
  998.     VFLG = CFLG = 0;
  999.     ZFLG = ((uae_s16)(src)) == 0;
  1000.     NFLG = ((uae_s16)(src)) < 0;
  1001.     put_word(dsta,src);
  1002. }}}}
  1003. void REGPARAM2 CPU_OP_NAME(_279)(uae_u32 opcode) /* AND */
  1004. {
  1005. {{    uae_s16 src = nextiword();
  1006. {    uaecptr dsta = nextilong();
  1007.     uae_s16 dst = get_word(dsta);
  1008.     src &= dst;
  1009.     VFLG = CFLG = 0;
  1010.     ZFLG = ((uae_s16)(src)) == 0;
  1011.     NFLG = ((uae_s16)(src)) < 0;
  1012.     put_word(dsta,src);
  1013. }}}}
  1014. void REGPARAM2 CPU_OP_NAME(_27c)(uae_u32 opcode) /* ANDSR */
  1015. {
  1016. {if (!regs.s) { regs.pc_p -= 2; Exception(8,0); } else
  1017. {    MakeSR();
  1018. {    uae_s16 src = nextiword();
  1019.     regs.sr &= src;
  1020.     MakeFromSR();
  1021. }}}}
  1022. void REGPARAM2 CPU_OP_NAME(_280)(uae_u32 opcode) /* AND */
  1023. {
  1024.     uae_u32 dstreg = opcode & 7;
  1025. {{    uae_s32 src = nextilong();
  1026. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  1027.     src &= dst;
  1028.     VFLG = CFLG = 0;
  1029.     ZFLG = ((uae_s32)(src)) == 0;
  1030.     NFLG = ((uae_s32)(src)) < 0;
  1031.     m68k_dreg(regs, dstreg) = (src);
  1032. }}}}
  1033. void REGPARAM2 CPU_OP_NAME(_290)(uae_u32 opcode) /* AND */
  1034. {
  1035.     uae_u32 dstreg = opcode & 7;
  1036. {{    uae_s32 src = nextilong();
  1037. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1038.     uae_s32 dst = get_long(dsta);
  1039.     src &= dst;
  1040.     VFLG = CFLG = 0;
  1041.     ZFLG = ((uae_s32)(src)) == 0;
  1042.     NFLG = ((uae_s32)(src)) < 0;
  1043.     put_long(dsta,src);
  1044. }}}}
  1045. void REGPARAM2 CPU_OP_NAME(_298)(uae_u32 opcode) /* AND */
  1046. {
  1047.     uae_u32 dstreg = opcode & 7;
  1048. {{    uae_s32 src = nextilong();
  1049. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1050.     uae_s32 dst = get_long(dsta);
  1051. {    m68k_areg(regs, dstreg) += 4;
  1052.     src &= dst;
  1053.     VFLG = CFLG = 0;
  1054.     ZFLG = ((uae_s32)(src)) == 0;
  1055.     NFLG = ((uae_s32)(src)) < 0;
  1056.     put_long(dsta,src);
  1057. }}}}}
  1058. void REGPARAM2 CPU_OP_NAME(_2a0)(uae_u32 opcode) /* AND */
  1059. {
  1060.     uae_u32 dstreg = opcode & 7;
  1061. {{    uae_s32 src = nextilong();
  1062. {    m68k_areg(regs, dstreg) -= 4;
  1063. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1064.     uae_s32 dst = get_long(dsta);
  1065.     src &= dst;
  1066.     VFLG = CFLG = 0;
  1067.     ZFLG = ((uae_s32)(src)) == 0;
  1068.     NFLG = ((uae_s32)(src)) < 0;
  1069.     put_long(dsta,src);
  1070. }}}}}
  1071. void REGPARAM2 CPU_OP_NAME(_2a8)(uae_u32 opcode) /* AND */
  1072. {
  1073.     uae_u32 dstreg = opcode & 7;
  1074. {{    uae_s32 src = nextilong();
  1075. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1076.     uae_s32 dst = get_long(dsta);
  1077.     src &= dst;
  1078.     VFLG = CFLG = 0;
  1079.     ZFLG = ((uae_s32)(src)) == 0;
  1080.     NFLG = ((uae_s32)(src)) < 0;
  1081.     put_long(dsta,src);
  1082. }}}}
  1083. void REGPARAM2 CPU_OP_NAME(_2b0)(uae_u32 opcode) /* AND */
  1084. {
  1085.     uae_u32 dstreg = opcode & 7;
  1086. {{    uae_s32 src = nextilong();
  1087. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1088. {    uae_s32 dst = get_long(dsta);
  1089.     src &= dst;
  1090.     VFLG = CFLG = 0;
  1091.     ZFLG = ((uae_s32)(src)) == 0;
  1092.     NFLG = ((uae_s32)(src)) < 0;
  1093.     put_long(dsta,src);
  1094. }}}}}
  1095. void REGPARAM2 CPU_OP_NAME(_2b8)(uae_u32 opcode) /* AND */
  1096. {
  1097. {{    uae_s32 src = nextilong();
  1098. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1099.     uae_s32 dst = get_long(dsta);
  1100.     src &= dst;
  1101.     VFLG = CFLG = 0;
  1102.     ZFLG = ((uae_s32)(src)) == 0;
  1103.     NFLG = ((uae_s32)(src)) < 0;
  1104.     put_long(dsta,src);
  1105. }}}}
  1106. void REGPARAM2 CPU_OP_NAME(_2b9)(uae_u32 opcode) /* AND */
  1107. {
  1108. {{    uae_s32 src = nextilong();
  1109. {    uaecptr dsta = nextilong();
  1110.     uae_s32 dst = get_long(dsta);
  1111.     src &= dst;
  1112.     VFLG = CFLG = 0;
  1113.     ZFLG = ((uae_s32)(src)) == 0;
  1114.     NFLG = ((uae_s32)(src)) < 0;
  1115.     put_long(dsta,src);
  1116. }}}}
  1117. void REGPARAM2 CPU_OP_NAME(_400)(uae_u32 opcode) /* SUB */
  1118. {
  1119.     uae_u32 dstreg = opcode & 7;
  1120. {{    uae_s8 src = nextibyte();
  1121. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  1122. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1123. {    int flgs = ((uae_s8)(src)) < 0;
  1124.     int flgo = ((uae_s8)(dst)) < 0;
  1125.     int flgn = ((uae_s8)(newv)) < 0;
  1126.     ZFLG = ((uae_s8)(newv)) == 0;
  1127.     VFLG = (flgs != flgo) && (flgn != flgo);
  1128.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1129.     NFLG = flgn != 0;
  1130.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((newv) & 0xff);
  1131. }}}}}}}
  1132. void REGPARAM2 CPU_OP_NAME(_410)(uae_u32 opcode) /* SUB */
  1133. {
  1134.     uae_u32 dstreg = opcode & 7;
  1135. {{    uae_s8 src = nextibyte();
  1136. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1137.     uae_s8 dst = get_byte(dsta);
  1138. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1139. {    int flgs = ((uae_s8)(src)) < 0;
  1140.     int flgo = ((uae_s8)(dst)) < 0;
  1141.     int flgn = ((uae_s8)(newv)) < 0;
  1142.     ZFLG = ((uae_s8)(newv)) == 0;
  1143.     VFLG = (flgs != flgo) && (flgn != flgo);
  1144.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1145.     NFLG = flgn != 0;
  1146.     put_byte(dsta,newv);
  1147. }}}}}}}
  1148. void REGPARAM2 CPU_OP_NAME(_418)(uae_u32 opcode) /* SUB */
  1149. {
  1150.     uae_u32 dstreg = opcode & 7;
  1151. {{    uae_s8 src = nextibyte();
  1152. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1153.     uae_s8 dst = get_byte(dsta);
  1154. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  1155. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1156. {    int flgs = ((uae_s8)(src)) < 0;
  1157.     int flgo = ((uae_s8)(dst)) < 0;
  1158.     int flgn = ((uae_s8)(newv)) < 0;
  1159.     ZFLG = ((uae_s8)(newv)) == 0;
  1160.     VFLG = (flgs != flgo) && (flgn != flgo);
  1161.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1162.     NFLG = flgn != 0;
  1163.     put_byte(dsta,newv);
  1164. }}}}}}}}
  1165. void REGPARAM2 CPU_OP_NAME(_420)(uae_u32 opcode) /* SUB */
  1166. {
  1167.     uae_u32 dstreg = opcode & 7;
  1168. {{    uae_s8 src = nextibyte();
  1169. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  1170. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1171.     uae_s8 dst = get_byte(dsta);
  1172. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1173. {    int flgs = ((uae_s8)(src)) < 0;
  1174.     int flgo = ((uae_s8)(dst)) < 0;
  1175.     int flgn = ((uae_s8)(newv)) < 0;
  1176.     ZFLG = ((uae_s8)(newv)) == 0;
  1177.     VFLG = (flgs != flgo) && (flgn != flgo);
  1178.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1179.     NFLG = flgn != 0;
  1180.     put_byte(dsta,newv);
  1181. }}}}}}}}
  1182. void REGPARAM2 CPU_OP_NAME(_428)(uae_u32 opcode) /* SUB */
  1183. {
  1184.     uae_u32 dstreg = opcode & 7;
  1185. {{    uae_s8 src = nextibyte();
  1186. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1187.     uae_s8 dst = get_byte(dsta);
  1188. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1189. {    int flgs = ((uae_s8)(src)) < 0;
  1190.     int flgo = ((uae_s8)(dst)) < 0;
  1191.     int flgn = ((uae_s8)(newv)) < 0;
  1192.     ZFLG = ((uae_s8)(newv)) == 0;
  1193.     VFLG = (flgs != flgo) && (flgn != flgo);
  1194.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1195.     NFLG = flgn != 0;
  1196.     put_byte(dsta,newv);
  1197. }}}}}}}
  1198. void REGPARAM2 CPU_OP_NAME(_430)(uae_u32 opcode) /* SUB */
  1199. {
  1200.     uae_u32 dstreg = opcode & 7;
  1201. {{    uae_s8 src = nextibyte();
  1202. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1203. {    uae_s8 dst = get_byte(dsta);
  1204. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1205. {    int flgs = ((uae_s8)(src)) < 0;
  1206.     int flgo = ((uae_s8)(dst)) < 0;
  1207.     int flgn = ((uae_s8)(newv)) < 0;
  1208.     ZFLG = ((uae_s8)(newv)) == 0;
  1209.     VFLG = (flgs != flgo) && (flgn != flgo);
  1210.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1211.     NFLG = flgn != 0;
  1212.     put_byte(dsta,newv);
  1213. }}}}}}}}
  1214. void REGPARAM2 CPU_OP_NAME(_438)(uae_u32 opcode) /* SUB */
  1215. {
  1216. {{    uae_s8 src = nextibyte();
  1217. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1218.     uae_s8 dst = get_byte(dsta);
  1219. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1220. {    int flgs = ((uae_s8)(src)) < 0;
  1221.     int flgo = ((uae_s8)(dst)) < 0;
  1222.     int flgn = ((uae_s8)(newv)) < 0;
  1223.     ZFLG = ((uae_s8)(newv)) == 0;
  1224.     VFLG = (flgs != flgo) && (flgn != flgo);
  1225.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1226.     NFLG = flgn != 0;
  1227.     put_byte(dsta,newv);
  1228. }}}}}}}
  1229. void REGPARAM2 CPU_OP_NAME(_439)(uae_u32 opcode) /* SUB */
  1230. {
  1231. {{    uae_s8 src = nextibyte();
  1232. {    uaecptr dsta = nextilong();
  1233.     uae_s8 dst = get_byte(dsta);
  1234. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  1235. {    int flgs = ((uae_s8)(src)) < 0;
  1236.     int flgo = ((uae_s8)(dst)) < 0;
  1237.     int flgn = ((uae_s8)(newv)) < 0;
  1238.     ZFLG = ((uae_s8)(newv)) == 0;
  1239.     VFLG = (flgs != flgo) && (flgn != flgo);
  1240.     CFLG = XFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  1241.     NFLG = flgn != 0;
  1242.     put_byte(dsta,newv);
  1243. }}}}}}}
  1244. void REGPARAM2 CPU_OP_NAME(_440)(uae_u32 opcode) /* SUB */
  1245. {
  1246.     uae_u32 dstreg = opcode & 7;
  1247. {{    uae_s16 src = nextiword();
  1248. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  1249. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1250. {    int flgs = ((uae_s16)(src)) < 0;
  1251.     int flgo = ((uae_s16)(dst)) < 0;
  1252.     int flgn = ((uae_s16)(newv)) < 0;
  1253.     ZFLG = ((uae_s16)(newv)) == 0;
  1254.     VFLG = (flgs != flgo) && (flgn != flgo);
  1255.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1256.     NFLG = flgn != 0;
  1257.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((newv) & 0xffff);
  1258. }}}}}}}
  1259. void REGPARAM2 CPU_OP_NAME(_450)(uae_u32 opcode) /* SUB */
  1260. {
  1261.     uae_u32 dstreg = opcode & 7;
  1262. {{    uae_s16 src = nextiword();
  1263. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1264.     uae_s16 dst = get_word(dsta);
  1265. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1266. {    int flgs = ((uae_s16)(src)) < 0;
  1267.     int flgo = ((uae_s16)(dst)) < 0;
  1268.     int flgn = ((uae_s16)(newv)) < 0;
  1269.     ZFLG = ((uae_s16)(newv)) == 0;
  1270.     VFLG = (flgs != flgo) && (flgn != flgo);
  1271.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1272.     NFLG = flgn != 0;
  1273.     put_word(dsta,newv);
  1274. }}}}}}}
  1275. void REGPARAM2 CPU_OP_NAME(_458)(uae_u32 opcode) /* SUB */
  1276. {
  1277.     uae_u32 dstreg = opcode & 7;
  1278. {{    uae_s16 src = nextiword();
  1279. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1280.     uae_s16 dst = get_word(dsta);
  1281. {    m68k_areg(regs, dstreg) += 2;
  1282. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1283. {    int flgs = ((uae_s16)(src)) < 0;
  1284.     int flgo = ((uae_s16)(dst)) < 0;
  1285.     int flgn = ((uae_s16)(newv)) < 0;
  1286.     ZFLG = ((uae_s16)(newv)) == 0;
  1287.     VFLG = (flgs != flgo) && (flgn != flgo);
  1288.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1289.     NFLG = flgn != 0;
  1290.     put_word(dsta,newv);
  1291. }}}}}}}}
  1292. void REGPARAM2 CPU_OP_NAME(_460)(uae_u32 opcode) /* SUB */
  1293. {
  1294.     uae_u32 dstreg = opcode & 7;
  1295. {{    uae_s16 src = nextiword();
  1296. {    m68k_areg(regs, dstreg) -= 2;
  1297. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1298.     uae_s16 dst = get_word(dsta);
  1299. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1300. {    int flgs = ((uae_s16)(src)) < 0;
  1301.     int flgo = ((uae_s16)(dst)) < 0;
  1302.     int flgn = ((uae_s16)(newv)) < 0;
  1303.     ZFLG = ((uae_s16)(newv)) == 0;
  1304.     VFLG = (flgs != flgo) && (flgn != flgo);
  1305.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1306.     NFLG = flgn != 0;
  1307.     put_word(dsta,newv);
  1308. }}}}}}}}
  1309. void REGPARAM2 CPU_OP_NAME(_468)(uae_u32 opcode) /* SUB */
  1310. {
  1311.     uae_u32 dstreg = opcode & 7;
  1312. {{    uae_s16 src = nextiword();
  1313. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1314.     uae_s16 dst = get_word(dsta);
  1315. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1316. {    int flgs = ((uae_s16)(src)) < 0;
  1317.     int flgo = ((uae_s16)(dst)) < 0;
  1318.     int flgn = ((uae_s16)(newv)) < 0;
  1319.     ZFLG = ((uae_s16)(newv)) == 0;
  1320.     VFLG = (flgs != flgo) && (flgn != flgo);
  1321.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1322.     NFLG = flgn != 0;
  1323.     put_word(dsta,newv);
  1324. }}}}}}}
  1325. void REGPARAM2 CPU_OP_NAME(_470)(uae_u32 opcode) /* SUB */
  1326. {
  1327.     uae_u32 dstreg = opcode & 7;
  1328. {{    uae_s16 src = nextiword();
  1329. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1330. {    uae_s16 dst = get_word(dsta);
  1331. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1332. {    int flgs = ((uae_s16)(src)) < 0;
  1333.     int flgo = ((uae_s16)(dst)) < 0;
  1334.     int flgn = ((uae_s16)(newv)) < 0;
  1335.     ZFLG = ((uae_s16)(newv)) == 0;
  1336.     VFLG = (flgs != flgo) && (flgn != flgo);
  1337.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1338.     NFLG = flgn != 0;
  1339.     put_word(dsta,newv);
  1340. }}}}}}}}
  1341. void REGPARAM2 CPU_OP_NAME(_478)(uae_u32 opcode) /* SUB */
  1342. {
  1343. {{    uae_s16 src = nextiword();
  1344. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1345.     uae_s16 dst = get_word(dsta);
  1346. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1347. {    int flgs = ((uae_s16)(src)) < 0;
  1348.     int flgo = ((uae_s16)(dst)) < 0;
  1349.     int flgn = ((uae_s16)(newv)) < 0;
  1350.     ZFLG = ((uae_s16)(newv)) == 0;
  1351.     VFLG = (flgs != flgo) && (flgn != flgo);
  1352.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1353.     NFLG = flgn != 0;
  1354.     put_word(dsta,newv);
  1355. }}}}}}}
  1356. void REGPARAM2 CPU_OP_NAME(_479)(uae_u32 opcode) /* SUB */
  1357. {
  1358. {{    uae_s16 src = nextiword();
  1359. {    uaecptr dsta = nextilong();
  1360.     uae_s16 dst = get_word(dsta);
  1361. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  1362. {    int flgs = ((uae_s16)(src)) < 0;
  1363.     int flgo = ((uae_s16)(dst)) < 0;
  1364.     int flgn = ((uae_s16)(newv)) < 0;
  1365.     ZFLG = ((uae_s16)(newv)) == 0;
  1366.     VFLG = (flgs != flgo) && (flgn != flgo);
  1367.     CFLG = XFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  1368.     NFLG = flgn != 0;
  1369.     put_word(dsta,newv);
  1370. }}}}}}}
  1371. void REGPARAM2 CPU_OP_NAME(_480)(uae_u32 opcode) /* SUB */
  1372. {
  1373.     uae_u32 dstreg = opcode & 7;
  1374. {{    uae_s32 src = nextilong();
  1375. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  1376. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1377. {    int flgs = ((uae_s32)(src)) < 0;
  1378.     int flgo = ((uae_s32)(dst)) < 0;
  1379.     int flgn = ((uae_s32)(newv)) < 0;
  1380.     ZFLG = ((uae_s32)(newv)) == 0;
  1381.     VFLG = (flgs != flgo) && (flgn != flgo);
  1382.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1383.     NFLG = flgn != 0;
  1384.     m68k_dreg(regs, dstreg) = (newv);
  1385. }}}}}}}
  1386. void REGPARAM2 CPU_OP_NAME(_490)(uae_u32 opcode) /* SUB */
  1387. {
  1388.     uae_u32 dstreg = opcode & 7;
  1389. {{    uae_s32 src = nextilong();
  1390. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1391.     uae_s32 dst = get_long(dsta);
  1392. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1393. {    int flgs = ((uae_s32)(src)) < 0;
  1394.     int flgo = ((uae_s32)(dst)) < 0;
  1395.     int flgn = ((uae_s32)(newv)) < 0;
  1396.     ZFLG = ((uae_s32)(newv)) == 0;
  1397.     VFLG = (flgs != flgo) && (flgn != flgo);
  1398.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1399.     NFLG = flgn != 0;
  1400.     put_long(dsta,newv);
  1401. }}}}}}}
  1402. void REGPARAM2 CPU_OP_NAME(_498)(uae_u32 opcode) /* SUB */
  1403. {
  1404.     uae_u32 dstreg = opcode & 7;
  1405. {{    uae_s32 src = nextilong();
  1406. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1407.     uae_s32 dst = get_long(dsta);
  1408. {    m68k_areg(regs, dstreg) += 4;
  1409. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1410. {    int flgs = ((uae_s32)(src)) < 0;
  1411.     int flgo = ((uae_s32)(dst)) < 0;
  1412.     int flgn = ((uae_s32)(newv)) < 0;
  1413.     ZFLG = ((uae_s32)(newv)) == 0;
  1414.     VFLG = (flgs != flgo) && (flgn != flgo);
  1415.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1416.     NFLG = flgn != 0;
  1417.     put_long(dsta,newv);
  1418. }}}}}}}}
  1419. void REGPARAM2 CPU_OP_NAME(_4a0)(uae_u32 opcode) /* SUB */
  1420. {
  1421.     uae_u32 dstreg = opcode & 7;
  1422. {{    uae_s32 src = nextilong();
  1423. {    m68k_areg(regs, dstreg) -= 4;
  1424. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1425.     uae_s32 dst = get_long(dsta);
  1426. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1427. {    int flgs = ((uae_s32)(src)) < 0;
  1428.     int flgo = ((uae_s32)(dst)) < 0;
  1429.     int flgn = ((uae_s32)(newv)) < 0;
  1430.     ZFLG = ((uae_s32)(newv)) == 0;
  1431.     VFLG = (flgs != flgo) && (flgn != flgo);
  1432.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1433.     NFLG = flgn != 0;
  1434.     put_long(dsta,newv);
  1435. }}}}}}}}
  1436. void REGPARAM2 CPU_OP_NAME(_4a8)(uae_u32 opcode) /* SUB */
  1437. {
  1438.     uae_u32 dstreg = opcode & 7;
  1439. {{    uae_s32 src = nextilong();
  1440. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1441.     uae_s32 dst = get_long(dsta);
  1442. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1443. {    int flgs = ((uae_s32)(src)) < 0;
  1444.     int flgo = ((uae_s32)(dst)) < 0;
  1445.     int flgn = ((uae_s32)(newv)) < 0;
  1446.     ZFLG = ((uae_s32)(newv)) == 0;
  1447.     VFLG = (flgs != flgo) && (flgn != flgo);
  1448.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1449.     NFLG = flgn != 0;
  1450.     put_long(dsta,newv);
  1451. }}}}}}}
  1452. void REGPARAM2 CPU_OP_NAME(_4b0)(uae_u32 opcode) /* SUB */
  1453. {
  1454.     uae_u32 dstreg = opcode & 7;
  1455. {{    uae_s32 src = nextilong();
  1456. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1457. {    uae_s32 dst = get_long(dsta);
  1458. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1459. {    int flgs = ((uae_s32)(src)) < 0;
  1460.     int flgo = ((uae_s32)(dst)) < 0;
  1461.     int flgn = ((uae_s32)(newv)) < 0;
  1462.     ZFLG = ((uae_s32)(newv)) == 0;
  1463.     VFLG = (flgs != flgo) && (flgn != flgo);
  1464.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1465.     NFLG = flgn != 0;
  1466.     put_long(dsta,newv);
  1467. }}}}}}}}
  1468. void REGPARAM2 CPU_OP_NAME(_4b8)(uae_u32 opcode) /* SUB */
  1469. {
  1470. {{    uae_s32 src = nextilong();
  1471. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1472.     uae_s32 dst = get_long(dsta);
  1473. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1474. {    int flgs = ((uae_s32)(src)) < 0;
  1475.     int flgo = ((uae_s32)(dst)) < 0;
  1476.     int flgn = ((uae_s32)(newv)) < 0;
  1477.     ZFLG = ((uae_s32)(newv)) == 0;
  1478.     VFLG = (flgs != flgo) && (flgn != flgo);
  1479.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1480.     NFLG = flgn != 0;
  1481.     put_long(dsta,newv);
  1482. }}}}}}}
  1483. void REGPARAM2 CPU_OP_NAME(_4b9)(uae_u32 opcode) /* SUB */
  1484. {
  1485. {{    uae_s32 src = nextilong();
  1486. {    uaecptr dsta = nextilong();
  1487.     uae_s32 dst = get_long(dsta);
  1488. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  1489. {    int flgs = ((uae_s32)(src)) < 0;
  1490.     int flgo = ((uae_s32)(dst)) < 0;
  1491.     int flgn = ((uae_s32)(newv)) < 0;
  1492.     ZFLG = ((uae_s32)(newv)) == 0;
  1493.     VFLG = (flgs != flgo) && (flgn != flgo);
  1494.     CFLG = XFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  1495.     NFLG = flgn != 0;
  1496.     put_long(dsta,newv);
  1497. }}}}}}}
  1498. void REGPARAM2 CPU_OP_NAME(_600)(uae_u32 opcode) /* ADD */
  1499. {
  1500.     uae_u32 dstreg = opcode & 7;
  1501. {{    uae_s8 src = nextibyte();
  1502. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  1503. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1504. {    int flgs = ((uae_s8)(src)) < 0;
  1505.     int flgo = ((uae_s8)(dst)) < 0;
  1506.     int flgn = ((uae_s8)(newv)) < 0;
  1507.     ZFLG = ((uae_s8)(newv)) == 0;
  1508.     VFLG = (flgs == flgo) && (flgn != flgo);
  1509.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1510.     NFLG = flgn != 0;
  1511.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((newv) & 0xff);
  1512. }}}}}}}
  1513. void REGPARAM2 CPU_OP_NAME(_610)(uae_u32 opcode) /* ADD */
  1514. {
  1515.     uae_u32 dstreg = opcode & 7;
  1516. {{    uae_s8 src = nextibyte();
  1517. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1518.     uae_s8 dst = get_byte(dsta);
  1519. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1520. {    int flgs = ((uae_s8)(src)) < 0;
  1521.     int flgo = ((uae_s8)(dst)) < 0;
  1522.     int flgn = ((uae_s8)(newv)) < 0;
  1523.     ZFLG = ((uae_s8)(newv)) == 0;
  1524.     VFLG = (flgs == flgo) && (flgn != flgo);
  1525.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1526.     NFLG = flgn != 0;
  1527.     put_byte(dsta,newv);
  1528. }}}}}}}
  1529. void REGPARAM2 CPU_OP_NAME(_618)(uae_u32 opcode) /* ADD */
  1530. {
  1531.     uae_u32 dstreg = opcode & 7;
  1532. {{    uae_s8 src = nextibyte();
  1533. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1534.     uae_s8 dst = get_byte(dsta);
  1535. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  1536. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1537. {    int flgs = ((uae_s8)(src)) < 0;
  1538.     int flgo = ((uae_s8)(dst)) < 0;
  1539.     int flgn = ((uae_s8)(newv)) < 0;
  1540.     ZFLG = ((uae_s8)(newv)) == 0;
  1541.     VFLG = (flgs == flgo) && (flgn != flgo);
  1542.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1543.     NFLG = flgn != 0;
  1544.     put_byte(dsta,newv);
  1545. }}}}}}}}
  1546. void REGPARAM2 CPU_OP_NAME(_620)(uae_u32 opcode) /* ADD */
  1547. {
  1548.     uae_u32 dstreg = opcode & 7;
  1549. {{    uae_s8 src = nextibyte();
  1550. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  1551. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1552.     uae_s8 dst = get_byte(dsta);
  1553. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1554. {    int flgs = ((uae_s8)(src)) < 0;
  1555.     int flgo = ((uae_s8)(dst)) < 0;
  1556.     int flgn = ((uae_s8)(newv)) < 0;
  1557.     ZFLG = ((uae_s8)(newv)) == 0;
  1558.     VFLG = (flgs == flgo) && (flgn != flgo);
  1559.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1560.     NFLG = flgn != 0;
  1561.     put_byte(dsta,newv);
  1562. }}}}}}}}
  1563. void REGPARAM2 CPU_OP_NAME(_628)(uae_u32 opcode) /* ADD */
  1564. {
  1565.     uae_u32 dstreg = opcode & 7;
  1566. {{    uae_s8 src = nextibyte();
  1567. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1568.     uae_s8 dst = get_byte(dsta);
  1569. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1570. {    int flgs = ((uae_s8)(src)) < 0;
  1571.     int flgo = ((uae_s8)(dst)) < 0;
  1572.     int flgn = ((uae_s8)(newv)) < 0;
  1573.     ZFLG = ((uae_s8)(newv)) == 0;
  1574.     VFLG = (flgs == flgo) && (flgn != flgo);
  1575.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1576.     NFLG = flgn != 0;
  1577.     put_byte(dsta,newv);
  1578. }}}}}}}
  1579. void REGPARAM2 CPU_OP_NAME(_630)(uae_u32 opcode) /* ADD */
  1580. {
  1581.     uae_u32 dstreg = opcode & 7;
  1582. {{    uae_s8 src = nextibyte();
  1583. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1584. {    uae_s8 dst = get_byte(dsta);
  1585. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1586. {    int flgs = ((uae_s8)(src)) < 0;
  1587.     int flgo = ((uae_s8)(dst)) < 0;
  1588.     int flgn = ((uae_s8)(newv)) < 0;
  1589.     ZFLG = ((uae_s8)(newv)) == 0;
  1590.     VFLG = (flgs == flgo) && (flgn != flgo);
  1591.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1592.     NFLG = flgn != 0;
  1593.     put_byte(dsta,newv);
  1594. }}}}}}}}
  1595. void REGPARAM2 CPU_OP_NAME(_638)(uae_u32 opcode) /* ADD */
  1596. {
  1597. {{    uae_s8 src = nextibyte();
  1598. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1599.     uae_s8 dst = get_byte(dsta);
  1600. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1601. {    int flgs = ((uae_s8)(src)) < 0;
  1602.     int flgo = ((uae_s8)(dst)) < 0;
  1603.     int flgn = ((uae_s8)(newv)) < 0;
  1604.     ZFLG = ((uae_s8)(newv)) == 0;
  1605.     VFLG = (flgs == flgo) && (flgn != flgo);
  1606.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1607.     NFLG = flgn != 0;
  1608.     put_byte(dsta,newv);
  1609. }}}}}}}
  1610. void REGPARAM2 CPU_OP_NAME(_639)(uae_u32 opcode) /* ADD */
  1611. {
  1612. {{    uae_s8 src = nextibyte();
  1613. {    uaecptr dsta = nextilong();
  1614.     uae_s8 dst = get_byte(dsta);
  1615. {{uae_u32 newv = ((uae_s8)(dst)) + ((uae_s8)(src));
  1616. {    int flgs = ((uae_s8)(src)) < 0;
  1617.     int flgo = ((uae_s8)(dst)) < 0;
  1618.     int flgn = ((uae_s8)(newv)) < 0;
  1619.     ZFLG = ((uae_s8)(newv)) == 0;
  1620.     VFLG = (flgs == flgo) && (flgn != flgo);
  1621.     CFLG = XFLG = ((uae_u8)(~dst)) < ((uae_u8)(src));
  1622.     NFLG = flgn != 0;
  1623.     put_byte(dsta,newv);
  1624. }}}}}}}
  1625. void REGPARAM2 CPU_OP_NAME(_640)(uae_u32 opcode) /* ADD */
  1626. {
  1627.     uae_u32 dstreg = opcode & 7;
  1628. {{    uae_s16 src = nextiword();
  1629. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  1630. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1631. {    int flgs = ((uae_s16)(src)) < 0;
  1632.     int flgo = ((uae_s16)(dst)) < 0;
  1633.     int flgn = ((uae_s16)(newv)) < 0;
  1634.     ZFLG = ((uae_s16)(newv)) == 0;
  1635.     VFLG = (flgs == flgo) && (flgn != flgo);
  1636.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1637.     NFLG = flgn != 0;
  1638.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((newv) & 0xffff);
  1639. }}}}}}}
  1640. void REGPARAM2 CPU_OP_NAME(_650)(uae_u32 opcode) /* ADD */
  1641. {
  1642.     uae_u32 dstreg = opcode & 7;
  1643. {{    uae_s16 src = nextiword();
  1644. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1645.     uae_s16 dst = get_word(dsta);
  1646. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1647. {    int flgs = ((uae_s16)(src)) < 0;
  1648.     int flgo = ((uae_s16)(dst)) < 0;
  1649.     int flgn = ((uae_s16)(newv)) < 0;
  1650.     ZFLG = ((uae_s16)(newv)) == 0;
  1651.     VFLG = (flgs == flgo) && (flgn != flgo);
  1652.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1653.     NFLG = flgn != 0;
  1654.     put_word(dsta,newv);
  1655. }}}}}}}
  1656. void REGPARAM2 CPU_OP_NAME(_658)(uae_u32 opcode) /* ADD */
  1657. {
  1658.     uae_u32 dstreg = opcode & 7;
  1659. {{    uae_s16 src = nextiword();
  1660. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1661.     uae_s16 dst = get_word(dsta);
  1662. {    m68k_areg(regs, dstreg) += 2;
  1663. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1664. {    int flgs = ((uae_s16)(src)) < 0;
  1665.     int flgo = ((uae_s16)(dst)) < 0;
  1666.     int flgn = ((uae_s16)(newv)) < 0;
  1667.     ZFLG = ((uae_s16)(newv)) == 0;
  1668.     VFLG = (flgs == flgo) && (flgn != flgo);
  1669.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1670.     NFLG = flgn != 0;
  1671.     put_word(dsta,newv);
  1672. }}}}}}}}
  1673. void REGPARAM2 CPU_OP_NAME(_660)(uae_u32 opcode) /* ADD */
  1674. {
  1675.     uae_u32 dstreg = opcode & 7;
  1676. {{    uae_s16 src = nextiword();
  1677. {    m68k_areg(regs, dstreg) -= 2;
  1678. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1679.     uae_s16 dst = get_word(dsta);
  1680. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1681. {    int flgs = ((uae_s16)(src)) < 0;
  1682.     int flgo = ((uae_s16)(dst)) < 0;
  1683.     int flgn = ((uae_s16)(newv)) < 0;
  1684.     ZFLG = ((uae_s16)(newv)) == 0;
  1685.     VFLG = (flgs == flgo) && (flgn != flgo);
  1686.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1687.     NFLG = flgn != 0;
  1688.     put_word(dsta,newv);
  1689. }}}}}}}}
  1690. void REGPARAM2 CPU_OP_NAME(_668)(uae_u32 opcode) /* ADD */
  1691. {
  1692.     uae_u32 dstreg = opcode & 7;
  1693. {{    uae_s16 src = nextiword();
  1694. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1695.     uae_s16 dst = get_word(dsta);
  1696. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1697. {    int flgs = ((uae_s16)(src)) < 0;
  1698.     int flgo = ((uae_s16)(dst)) < 0;
  1699.     int flgn = ((uae_s16)(newv)) < 0;
  1700.     ZFLG = ((uae_s16)(newv)) == 0;
  1701.     VFLG = (flgs == flgo) && (flgn != flgo);
  1702.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1703.     NFLG = flgn != 0;
  1704.     put_word(dsta,newv);
  1705. }}}}}}}
  1706. void REGPARAM2 CPU_OP_NAME(_670)(uae_u32 opcode) /* ADD */
  1707. {
  1708.     uae_u32 dstreg = opcode & 7;
  1709. {{    uae_s16 src = nextiword();
  1710. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1711. {    uae_s16 dst = get_word(dsta);
  1712. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1713. {    int flgs = ((uae_s16)(src)) < 0;
  1714.     int flgo = ((uae_s16)(dst)) < 0;
  1715.     int flgn = ((uae_s16)(newv)) < 0;
  1716.     ZFLG = ((uae_s16)(newv)) == 0;
  1717.     VFLG = (flgs == flgo) && (flgn != flgo);
  1718.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1719.     NFLG = flgn != 0;
  1720.     put_word(dsta,newv);
  1721. }}}}}}}}
  1722. void REGPARAM2 CPU_OP_NAME(_678)(uae_u32 opcode) /* ADD */
  1723. {
  1724. {{    uae_s16 src = nextiword();
  1725. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1726.     uae_s16 dst = get_word(dsta);
  1727. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1728. {    int flgs = ((uae_s16)(src)) < 0;
  1729.     int flgo = ((uae_s16)(dst)) < 0;
  1730.     int flgn = ((uae_s16)(newv)) < 0;
  1731.     ZFLG = ((uae_s16)(newv)) == 0;
  1732.     VFLG = (flgs == flgo) && (flgn != flgo);
  1733.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1734.     NFLG = flgn != 0;
  1735.     put_word(dsta,newv);
  1736. }}}}}}}
  1737. void REGPARAM2 CPU_OP_NAME(_679)(uae_u32 opcode) /* ADD */
  1738. {
  1739. {{    uae_s16 src = nextiword();
  1740. {    uaecptr dsta = nextilong();
  1741.     uae_s16 dst = get_word(dsta);
  1742. {{uae_u32 newv = ((uae_s16)(dst)) + ((uae_s16)(src));
  1743. {    int flgs = ((uae_s16)(src)) < 0;
  1744.     int flgo = ((uae_s16)(dst)) < 0;
  1745.     int flgn = ((uae_s16)(newv)) < 0;
  1746.     ZFLG = ((uae_s16)(newv)) == 0;
  1747.     VFLG = (flgs == flgo) && (flgn != flgo);
  1748.     CFLG = XFLG = ((uae_u16)(~dst)) < ((uae_u16)(src));
  1749.     NFLG = flgn != 0;
  1750.     put_word(dsta,newv);
  1751. }}}}}}}
  1752. void REGPARAM2 CPU_OP_NAME(_680)(uae_u32 opcode) /* ADD */
  1753. {
  1754.     uae_u32 dstreg = opcode & 7;
  1755. {{    uae_s32 src = nextilong();
  1756. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  1757. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1758. {    int flgs = ((uae_s32)(src)) < 0;
  1759.     int flgo = ((uae_s32)(dst)) < 0;
  1760.     int flgn = ((uae_s32)(newv)) < 0;
  1761.     ZFLG = ((uae_s32)(newv)) == 0;
  1762.     VFLG = (flgs == flgo) && (flgn != flgo);
  1763.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1764.     NFLG = flgn != 0;
  1765.     m68k_dreg(regs, dstreg) = (newv);
  1766. }}}}}}}
  1767. void REGPARAM2 CPU_OP_NAME(_690)(uae_u32 opcode) /* ADD */
  1768. {
  1769.     uae_u32 dstreg = opcode & 7;
  1770. {{    uae_s32 src = nextilong();
  1771. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1772.     uae_s32 dst = get_long(dsta);
  1773. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1774. {    int flgs = ((uae_s32)(src)) < 0;
  1775.     int flgo = ((uae_s32)(dst)) < 0;
  1776.     int flgn = ((uae_s32)(newv)) < 0;
  1777.     ZFLG = ((uae_s32)(newv)) == 0;
  1778.     VFLG = (flgs == flgo) && (flgn != flgo);
  1779.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1780.     NFLG = flgn != 0;
  1781.     put_long(dsta,newv);
  1782. }}}}}}}
  1783. void REGPARAM2 CPU_OP_NAME(_698)(uae_u32 opcode) /* ADD */
  1784. {
  1785.     uae_u32 dstreg = opcode & 7;
  1786. {{    uae_s32 src = nextilong();
  1787. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1788.     uae_s32 dst = get_long(dsta);
  1789. {    m68k_areg(regs, dstreg) += 4;
  1790. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1791. {    int flgs = ((uae_s32)(src)) < 0;
  1792.     int flgo = ((uae_s32)(dst)) < 0;
  1793.     int flgn = ((uae_s32)(newv)) < 0;
  1794.     ZFLG = ((uae_s32)(newv)) == 0;
  1795.     VFLG = (flgs == flgo) && (flgn != flgo);
  1796.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1797.     NFLG = flgn != 0;
  1798.     put_long(dsta,newv);
  1799. }}}}}}}}
  1800. void REGPARAM2 CPU_OP_NAME(_6a0)(uae_u32 opcode) /* ADD */
  1801. {
  1802.     uae_u32 dstreg = opcode & 7;
  1803. {{    uae_s32 src = nextilong();
  1804. {    m68k_areg(regs, dstreg) -= 4;
  1805. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1806.     uae_s32 dst = get_long(dsta);
  1807. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1808. {    int flgs = ((uae_s32)(src)) < 0;
  1809.     int flgo = ((uae_s32)(dst)) < 0;
  1810.     int flgn = ((uae_s32)(newv)) < 0;
  1811.     ZFLG = ((uae_s32)(newv)) == 0;
  1812.     VFLG = (flgs == flgo) && (flgn != flgo);
  1813.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1814.     NFLG = flgn != 0;
  1815.     put_long(dsta,newv);
  1816. }}}}}}}}
  1817. void REGPARAM2 CPU_OP_NAME(_6a8)(uae_u32 opcode) /* ADD */
  1818. {
  1819.     uae_u32 dstreg = opcode & 7;
  1820. {{    uae_s32 src = nextilong();
  1821. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1822.     uae_s32 dst = get_long(dsta);
  1823. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1824. {    int flgs = ((uae_s32)(src)) < 0;
  1825.     int flgo = ((uae_s32)(dst)) < 0;
  1826.     int flgn = ((uae_s32)(newv)) < 0;
  1827.     ZFLG = ((uae_s32)(newv)) == 0;
  1828.     VFLG = (flgs == flgo) && (flgn != flgo);
  1829.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1830.     NFLG = flgn != 0;
  1831.     put_long(dsta,newv);
  1832. }}}}}}}
  1833. void REGPARAM2 CPU_OP_NAME(_6b0)(uae_u32 opcode) /* ADD */
  1834. {
  1835.     uae_u32 dstreg = opcode & 7;
  1836. {{    uae_s32 src = nextilong();
  1837. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1838. {    uae_s32 dst = get_long(dsta);
  1839. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1840. {    int flgs = ((uae_s32)(src)) < 0;
  1841.     int flgo = ((uae_s32)(dst)) < 0;
  1842.     int flgn = ((uae_s32)(newv)) < 0;
  1843.     ZFLG = ((uae_s32)(newv)) == 0;
  1844.     VFLG = (flgs == flgo) && (flgn != flgo);
  1845.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1846.     NFLG = flgn != 0;
  1847.     put_long(dsta,newv);
  1848. }}}}}}}}
  1849. void REGPARAM2 CPU_OP_NAME(_6b8)(uae_u32 opcode) /* ADD */
  1850. {
  1851. {{    uae_s32 src = nextilong();
  1852. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1853.     uae_s32 dst = get_long(dsta);
  1854. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1855. {    int flgs = ((uae_s32)(src)) < 0;
  1856.     int flgo = ((uae_s32)(dst)) < 0;
  1857.     int flgn = ((uae_s32)(newv)) < 0;
  1858.     ZFLG = ((uae_s32)(newv)) == 0;
  1859.     VFLG = (flgs == flgo) && (flgn != flgo);
  1860.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1861.     NFLG = flgn != 0;
  1862.     put_long(dsta,newv);
  1863. }}}}}}}
  1864. void REGPARAM2 CPU_OP_NAME(_6b9)(uae_u32 opcode) /* ADD */
  1865. {
  1866. {{    uae_s32 src = nextilong();
  1867. {    uaecptr dsta = nextilong();
  1868.     uae_s32 dst = get_long(dsta);
  1869. {{uae_u32 newv = ((uae_s32)(dst)) + ((uae_s32)(src));
  1870. {    int flgs = ((uae_s32)(src)) < 0;
  1871.     int flgo = ((uae_s32)(dst)) < 0;
  1872.     int flgn = ((uae_s32)(newv)) < 0;
  1873.     ZFLG = ((uae_s32)(newv)) == 0;
  1874.     VFLG = (flgs == flgo) && (flgn != flgo);
  1875.     CFLG = XFLG = ((uae_u32)(~dst)) < ((uae_u32)(src));
  1876.     NFLG = flgn != 0;
  1877.     put_long(dsta,newv);
  1878. }}}}}}}
  1879. void REGPARAM2 CPU_OP_NAME(_800)(uae_u32 opcode) /* BTST */
  1880. {
  1881.     uae_u32 dstreg = opcode & 7;
  1882. {{    uae_s16 src = nextiword();
  1883. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  1884.     src &= 31;
  1885.     ZFLG = !(dst & (1 << src));
  1886. }}}}
  1887. void REGPARAM2 CPU_OP_NAME(_810)(uae_u32 opcode) /* BTST */
  1888. {
  1889.     uae_u32 dstreg = opcode & 7;
  1890. {{    uae_s16 src = nextiword();
  1891. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1892.     uae_s8 dst = get_byte(dsta);
  1893.     src &= 7;
  1894.     ZFLG = !(dst & (1 << src));
  1895. }}}}
  1896. void REGPARAM2 CPU_OP_NAME(_818)(uae_u32 opcode) /* BTST */
  1897. {
  1898.     uae_u32 dstreg = opcode & 7;
  1899. {{    uae_s16 src = nextiword();
  1900. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1901.     uae_s8 dst = get_byte(dsta);
  1902. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  1903.     src &= 7;
  1904.     ZFLG = !(dst & (1 << src));
  1905. }}}}}
  1906. void REGPARAM2 CPU_OP_NAME(_820)(uae_u32 opcode) /* BTST */
  1907. {
  1908.     uae_u32 dstreg = opcode & 7;
  1909. {{    uae_s16 src = nextiword();
  1910. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  1911. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1912.     uae_s8 dst = get_byte(dsta);
  1913.     src &= 7;
  1914.     ZFLG = !(dst & (1 << src));
  1915. }}}}}
  1916. void REGPARAM2 CPU_OP_NAME(_828)(uae_u32 opcode) /* BTST */
  1917. {
  1918.     uae_u32 dstreg = opcode & 7;
  1919. {{    uae_s16 src = nextiword();
  1920. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  1921.     uae_s8 dst = get_byte(dsta);
  1922.     src &= 7;
  1923.     ZFLG = !(dst & (1 << src));
  1924. }}}}
  1925. void REGPARAM2 CPU_OP_NAME(_830)(uae_u32 opcode) /* BTST */
  1926. {
  1927.     uae_u32 dstreg = opcode & 7;
  1928. {{    uae_s16 src = nextiword();
  1929. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  1930. {    uae_s8 dst = get_byte(dsta);
  1931.     src &= 7;
  1932.     ZFLG = !(dst & (1 << src));
  1933. }}}}}
  1934. void REGPARAM2 CPU_OP_NAME(_838)(uae_u32 opcode) /* BTST */
  1935. {
  1936. {{    uae_s16 src = nextiword();
  1937. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  1938.     uae_s8 dst = get_byte(dsta);
  1939.     src &= 7;
  1940.     ZFLG = !(dst & (1 << src));
  1941. }}}}
  1942. void REGPARAM2 CPU_OP_NAME(_839)(uae_u32 opcode) /* BTST */
  1943. {
  1944. {{    uae_s16 src = nextiword();
  1945. {    uaecptr dsta = nextilong();
  1946.     uae_s8 dst = get_byte(dsta);
  1947.     src &= 7;
  1948.     ZFLG = !(dst & (1 << src));
  1949. }}}}
  1950. void REGPARAM2 CPU_OP_NAME(_83a)(uae_u32 opcode) /* BTST */
  1951. {
  1952.     uae_u32 dstreg = 2;
  1953. {{    uae_s16 src = nextiword();
  1954. {    uaecptr dsta = m68k_getpc();
  1955.     dsta += (uae_s32)(uae_s16)nextiword();
  1956. {    uae_s8 dst = get_byte(dsta);
  1957.     src &= 7;
  1958.     ZFLG = !(dst & (1 << src));
  1959. }}}}}
  1960. void REGPARAM2 CPU_OP_NAME(_83b)(uae_u32 opcode) /* BTST */
  1961. {
  1962.     uae_u32 dstreg = 3;
  1963. {{    uae_s16 src = nextiword();
  1964. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  1965. {    uae_s8 dst = get_byte(dsta);
  1966.     src &= 7;
  1967.     ZFLG = !(dst & (1 << src));
  1968. }}}}}
  1969. void REGPARAM2 CPU_OP_NAME(_83c)(uae_u32 opcode) /* BTST */
  1970. {
  1971. {{    uae_s16 src = nextiword();
  1972. {    uae_s8 dst = nextibyte();
  1973.     src &= 7;
  1974.     ZFLG = !(dst & (1 << src));
  1975. }}}}
  1976. void REGPARAM2 CPU_OP_NAME(_840)(uae_u32 opcode) /* BCHG */
  1977. {
  1978.     uae_u32 dstreg = opcode & 7;
  1979. {{    uae_s16 src = nextiword();
  1980. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  1981.     src &= 31;
  1982.     ZFLG = !(dst & (1 << src));
  1983.     dst ^= (1 << src);
  1984.     m68k_dreg(regs, dstreg) = (dst);
  1985. }}}}
  1986. void REGPARAM2 CPU_OP_NAME(_850)(uae_u32 opcode) /* BCHG */
  1987. {
  1988.     uae_u32 dstreg = opcode & 7;
  1989. {{    uae_s16 src = nextiword();
  1990. {    uaecptr dsta = m68k_areg(regs, dstreg);
  1991.     uae_s8 dst = get_byte(dsta);
  1992.     src &= 7;
  1993.     ZFLG = !(dst & (1 << src));
  1994.     dst ^= (1 << src);
  1995.     put_byte(dsta,dst);
  1996. }}}}
  1997. void REGPARAM2 CPU_OP_NAME(_858)(uae_u32 opcode) /* BCHG */
  1998. {
  1999.     uae_u32 dstreg = opcode & 7;
  2000. {{    uae_s16 src = nextiword();
  2001. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2002.     uae_s8 dst = get_byte(dsta);
  2003. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  2004.     src &= 7;
  2005.     ZFLG = !(dst & (1 << src));
  2006.     dst ^= (1 << src);
  2007.     put_byte(dsta,dst);
  2008. }}}}}
  2009. void REGPARAM2 CPU_OP_NAME(_860)(uae_u32 opcode) /* BCHG */
  2010. {
  2011.     uae_u32 dstreg = opcode & 7;
  2012. {{    uae_s16 src = nextiword();
  2013. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  2014. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2015.     uae_s8 dst = get_byte(dsta);
  2016.     src &= 7;
  2017.     ZFLG = !(dst & (1 << src));
  2018.     dst ^= (1 << src);
  2019.     put_byte(dsta,dst);
  2020. }}}}}
  2021. void REGPARAM2 CPU_OP_NAME(_868)(uae_u32 opcode) /* BCHG */
  2022. {
  2023.     uae_u32 dstreg = opcode & 7;
  2024. {{    uae_s16 src = nextiword();
  2025. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2026.     uae_s8 dst = get_byte(dsta);
  2027.     src &= 7;
  2028.     ZFLG = !(dst & (1 << src));
  2029.     dst ^= (1 << src);
  2030.     put_byte(dsta,dst);
  2031. }}}}
  2032. void REGPARAM2 CPU_OP_NAME(_870)(uae_u32 opcode) /* BCHG */
  2033. {
  2034.     uae_u32 dstreg = opcode & 7;
  2035. {{    uae_s16 src = nextiword();
  2036. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2037. {    uae_s8 dst = get_byte(dsta);
  2038.     src &= 7;
  2039.     ZFLG = !(dst & (1 << src));
  2040.     dst ^= (1 << src);
  2041.     put_byte(dsta,dst);
  2042. }}}}}
  2043. void REGPARAM2 CPU_OP_NAME(_878)(uae_u32 opcode) /* BCHG */
  2044. {
  2045. {{    uae_s16 src = nextiword();
  2046. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2047.     uae_s8 dst = get_byte(dsta);
  2048.     src &= 7;
  2049.     ZFLG = !(dst & (1 << src));
  2050.     dst ^= (1 << src);
  2051.     put_byte(dsta,dst);
  2052. }}}}
  2053. void REGPARAM2 CPU_OP_NAME(_879)(uae_u32 opcode) /* BCHG */
  2054. {
  2055. {{    uae_s16 src = nextiword();
  2056. {    uaecptr dsta = nextilong();
  2057.     uae_s8 dst = get_byte(dsta);
  2058.     src &= 7;
  2059.     ZFLG = !(dst & (1 << src));
  2060.     dst ^= (1 << src);
  2061.     put_byte(dsta,dst);
  2062. }}}}
  2063. void REGPARAM2 CPU_OP_NAME(_87a)(uae_u32 opcode) /* BCHG */
  2064. {
  2065.     uae_u32 dstreg = 2;
  2066. {{    uae_s16 src = nextiword();
  2067. {    uaecptr dsta = m68k_getpc();
  2068.     dsta += (uae_s32)(uae_s16)nextiword();
  2069. {    uae_s8 dst = get_byte(dsta);
  2070.     src &= 7;
  2071.     ZFLG = !(dst & (1 << src));
  2072.     dst ^= (1 << src);
  2073.     put_byte(dsta,dst);
  2074. }}}}}
  2075. void REGPARAM2 CPU_OP_NAME(_87b)(uae_u32 opcode) /* BCHG */
  2076. {
  2077.     uae_u32 dstreg = 3;
  2078. {{    uae_s16 src = nextiword();
  2079. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  2080. {    uae_s8 dst = get_byte(dsta);
  2081.     src &= 7;
  2082.     ZFLG = !(dst & (1 << src));
  2083.     dst ^= (1 << src);
  2084.     put_byte(dsta,dst);
  2085. }}}}}
  2086. void REGPARAM2 CPU_OP_NAME(_880)(uae_u32 opcode) /* BCLR */
  2087. {
  2088.     uae_u32 dstreg = opcode & 7;
  2089. {{    uae_s16 src = nextiword();
  2090. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  2091.     src &= 31;
  2092.     ZFLG = !(dst & (1 << src));
  2093.     dst &= ~(1 << src);
  2094.     m68k_dreg(regs, dstreg) = (dst);
  2095. }}}}
  2096. void REGPARAM2 CPU_OP_NAME(_890)(uae_u32 opcode) /* BCLR */
  2097. {
  2098.     uae_u32 dstreg = opcode & 7;
  2099. {{    uae_s16 src = nextiword();
  2100. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2101.     uae_s8 dst = get_byte(dsta);
  2102.     src &= 7;
  2103.     ZFLG = !(dst & (1 << src));
  2104.     dst &= ~(1 << src);
  2105.     put_byte(dsta,dst);
  2106. }}}}
  2107. void REGPARAM2 CPU_OP_NAME(_898)(uae_u32 opcode) /* BCLR */
  2108. {
  2109.     uae_u32 dstreg = opcode & 7;
  2110. {{    uae_s16 src = nextiword();
  2111. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2112.     uae_s8 dst = get_byte(dsta);
  2113. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  2114.     src &= 7;
  2115.     ZFLG = !(dst & (1 << src));
  2116.     dst &= ~(1 << src);
  2117.     put_byte(dsta,dst);
  2118. }}}}}
  2119. void REGPARAM2 CPU_OP_NAME(_8a0)(uae_u32 opcode) /* BCLR */
  2120. {
  2121.     uae_u32 dstreg = opcode & 7;
  2122. {{    uae_s16 src = nextiword();
  2123. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  2124. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2125.     uae_s8 dst = get_byte(dsta);
  2126.     src &= 7;
  2127.     ZFLG = !(dst & (1 << src));
  2128.     dst &= ~(1 << src);
  2129.     put_byte(dsta,dst);
  2130. }}}}}
  2131. void REGPARAM2 CPU_OP_NAME(_8a8)(uae_u32 opcode) /* BCLR */
  2132. {
  2133.     uae_u32 dstreg = opcode & 7;
  2134. {{    uae_s16 src = nextiword();
  2135. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2136.     uae_s8 dst = get_byte(dsta);
  2137.     src &= 7;
  2138.     ZFLG = !(dst & (1 << src));
  2139.     dst &= ~(1 << src);
  2140.     put_byte(dsta,dst);
  2141. }}}}
  2142. void REGPARAM2 CPU_OP_NAME(_8b0)(uae_u32 opcode) /* BCLR */
  2143. {
  2144.     uae_u32 dstreg = opcode & 7;
  2145. {{    uae_s16 src = nextiword();
  2146. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2147. {    uae_s8 dst = get_byte(dsta);
  2148.     src &= 7;
  2149.     ZFLG = !(dst & (1 << src));
  2150.     dst &= ~(1 << src);
  2151.     put_byte(dsta,dst);
  2152. }}}}}
  2153. void REGPARAM2 CPU_OP_NAME(_8b8)(uae_u32 opcode) /* BCLR */
  2154. {
  2155. {{    uae_s16 src = nextiword();
  2156. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2157.     uae_s8 dst = get_byte(dsta);
  2158.     src &= 7;
  2159.     ZFLG = !(dst & (1 << src));
  2160.     dst &= ~(1 << src);
  2161.     put_byte(dsta,dst);
  2162. }}}}
  2163. void REGPARAM2 CPU_OP_NAME(_8b9)(uae_u32 opcode) /* BCLR */
  2164. {
  2165. {{    uae_s16 src = nextiword();
  2166. {    uaecptr dsta = nextilong();
  2167.     uae_s8 dst = get_byte(dsta);
  2168.     src &= 7;
  2169.     ZFLG = !(dst & (1 << src));
  2170.     dst &= ~(1 << src);
  2171.     put_byte(dsta,dst);
  2172. }}}}
  2173. void REGPARAM2 CPU_OP_NAME(_8ba)(uae_u32 opcode) /* BCLR */
  2174. {
  2175.     uae_u32 dstreg = 2;
  2176. {{    uae_s16 src = nextiword();
  2177. {    uaecptr dsta = m68k_getpc();
  2178.     dsta += (uae_s32)(uae_s16)nextiword();
  2179. {    uae_s8 dst = get_byte(dsta);
  2180.     src &= 7;
  2181.     ZFLG = !(dst & (1 << src));
  2182.     dst &= ~(1 << src);
  2183.     put_byte(dsta,dst);
  2184. }}}}}
  2185. void REGPARAM2 CPU_OP_NAME(_8bb)(uae_u32 opcode) /* BCLR */
  2186. {
  2187.     uae_u32 dstreg = 3;
  2188. {{    uae_s16 src = nextiword();
  2189. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  2190. {    uae_s8 dst = get_byte(dsta);
  2191.     src &= 7;
  2192.     ZFLG = !(dst & (1 << src));
  2193.     dst &= ~(1 << src);
  2194.     put_byte(dsta,dst);
  2195. }}}}}
  2196. void REGPARAM2 CPU_OP_NAME(_8c0)(uae_u32 opcode) /* BSET */
  2197. {
  2198.     uae_u32 dstreg = opcode & 7;
  2199. {{    uae_s16 src = nextiword();
  2200. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  2201.     src &= 31;
  2202.     ZFLG = !(dst & (1 << src));
  2203.     dst |= (1 << src);
  2204.     m68k_dreg(regs, dstreg) = (dst);
  2205. }}}}
  2206. void REGPARAM2 CPU_OP_NAME(_8d0)(uae_u32 opcode) /* BSET */
  2207. {
  2208.     uae_u32 dstreg = opcode & 7;
  2209. {{    uae_s16 src = nextiword();
  2210. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2211.     uae_s8 dst = get_byte(dsta);
  2212.     src &= 7;
  2213.     ZFLG = !(dst & (1 << src));
  2214.     dst |= (1 << src);
  2215.     put_byte(dsta,dst);
  2216. }}}}
  2217. void REGPARAM2 CPU_OP_NAME(_8d8)(uae_u32 opcode) /* BSET */
  2218. {
  2219.     uae_u32 dstreg = opcode & 7;
  2220. {{    uae_s16 src = nextiword();
  2221. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2222.     uae_s8 dst = get_byte(dsta);
  2223. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  2224.     src &= 7;
  2225.     ZFLG = !(dst & (1 << src));
  2226.     dst |= (1 << src);
  2227.     put_byte(dsta,dst);
  2228. }}}}}
  2229. void REGPARAM2 CPU_OP_NAME(_8e0)(uae_u32 opcode) /* BSET */
  2230. {
  2231.     uae_u32 dstreg = opcode & 7;
  2232. {{    uae_s16 src = nextiword();
  2233. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  2234. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2235.     uae_s8 dst = get_byte(dsta);
  2236.     src &= 7;
  2237.     ZFLG = !(dst & (1 << src));
  2238.     dst |= (1 << src);
  2239.     put_byte(dsta,dst);
  2240. }}}}}
  2241. void REGPARAM2 CPU_OP_NAME(_8e8)(uae_u32 opcode) /* BSET */
  2242. {
  2243.     uae_u32 dstreg = opcode & 7;
  2244. {{    uae_s16 src = nextiword();
  2245. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2246.     uae_s8 dst = get_byte(dsta);
  2247.     src &= 7;
  2248.     ZFLG = !(dst & (1 << src));
  2249.     dst |= (1 << src);
  2250.     put_byte(dsta,dst);
  2251. }}}}
  2252. void REGPARAM2 CPU_OP_NAME(_8f0)(uae_u32 opcode) /* BSET */
  2253. {
  2254.     uae_u32 dstreg = opcode & 7;
  2255. {{    uae_s16 src = nextiword();
  2256. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2257. {    uae_s8 dst = get_byte(dsta);
  2258.     src &= 7;
  2259.     ZFLG = !(dst & (1 << src));
  2260.     dst |= (1 << src);
  2261.     put_byte(dsta,dst);
  2262. }}}}}
  2263. void REGPARAM2 CPU_OP_NAME(_8f8)(uae_u32 opcode) /* BSET */
  2264. {
  2265. {{    uae_s16 src = nextiword();
  2266. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2267.     uae_s8 dst = get_byte(dsta);
  2268.     src &= 7;
  2269.     ZFLG = !(dst & (1 << src));
  2270.     dst |= (1 << src);
  2271.     put_byte(dsta,dst);
  2272. }}}}
  2273. void REGPARAM2 CPU_OP_NAME(_8f9)(uae_u32 opcode) /* BSET */
  2274. {
  2275. {{    uae_s16 src = nextiword();
  2276. {    uaecptr dsta = nextilong();
  2277.     uae_s8 dst = get_byte(dsta);
  2278.     src &= 7;
  2279.     ZFLG = !(dst & (1 << src));
  2280.     dst |= (1 << src);
  2281.     put_byte(dsta,dst);
  2282. }}}}
  2283. void REGPARAM2 CPU_OP_NAME(_8fa)(uae_u32 opcode) /* BSET */
  2284. {
  2285.     uae_u32 dstreg = 2;
  2286. {{    uae_s16 src = nextiword();
  2287. {    uaecptr dsta = m68k_getpc();
  2288.     dsta += (uae_s32)(uae_s16)nextiword();
  2289. {    uae_s8 dst = get_byte(dsta);
  2290.     src &= 7;
  2291.     ZFLG = !(dst & (1 << src));
  2292.     dst |= (1 << src);
  2293.     put_byte(dsta,dst);
  2294. }}}}}
  2295. void REGPARAM2 CPU_OP_NAME(_8fb)(uae_u32 opcode) /* BSET */
  2296. {
  2297.     uae_u32 dstreg = 3;
  2298. {{    uae_s16 src = nextiword();
  2299. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  2300. {    uae_s8 dst = get_byte(dsta);
  2301.     src &= 7;
  2302.     ZFLG = !(dst & (1 << src));
  2303.     dst |= (1 << src);
  2304.     put_byte(dsta,dst);
  2305. }}}}}
  2306. void REGPARAM2 CPU_OP_NAME(_a00)(uae_u32 opcode) /* EOR */
  2307. {
  2308.     uae_u32 dstreg = opcode & 7;
  2309. {{    uae_s8 src = nextibyte();
  2310. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  2311.     src ^= dst;
  2312.     VFLG = CFLG = 0;
  2313.     ZFLG = ((uae_s8)(src)) == 0;
  2314.     NFLG = ((uae_s8)(src)) < 0;
  2315.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((src) & 0xff);
  2316. }}}}
  2317. void REGPARAM2 CPU_OP_NAME(_a10)(uae_u32 opcode) /* EOR */
  2318. {
  2319.     uae_u32 dstreg = opcode & 7;
  2320. {{    uae_s8 src = nextibyte();
  2321. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2322.     uae_s8 dst = get_byte(dsta);
  2323.     src ^= dst;
  2324.     VFLG = CFLG = 0;
  2325.     ZFLG = ((uae_s8)(src)) == 0;
  2326.     NFLG = ((uae_s8)(src)) < 0;
  2327.     put_byte(dsta,src);
  2328. }}}}
  2329. void REGPARAM2 CPU_OP_NAME(_a18)(uae_u32 opcode) /* EOR */
  2330. {
  2331.     uae_u32 dstreg = opcode & 7;
  2332. {{    uae_s8 src = nextibyte();
  2333. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2334.     uae_s8 dst = get_byte(dsta);
  2335. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  2336.     src ^= dst;
  2337.     VFLG = CFLG = 0;
  2338.     ZFLG = ((uae_s8)(src)) == 0;
  2339.     NFLG = ((uae_s8)(src)) < 0;
  2340.     put_byte(dsta,src);
  2341. }}}}}
  2342. void REGPARAM2 CPU_OP_NAME(_a20)(uae_u32 opcode) /* EOR */
  2343. {
  2344.     uae_u32 dstreg = opcode & 7;
  2345. {{    uae_s8 src = nextibyte();
  2346. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  2347. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2348.     uae_s8 dst = get_byte(dsta);
  2349.     src ^= dst;
  2350.     VFLG = CFLG = 0;
  2351.     ZFLG = ((uae_s8)(src)) == 0;
  2352.     NFLG = ((uae_s8)(src)) < 0;
  2353.     put_byte(dsta,src);
  2354. }}}}}
  2355. void REGPARAM2 CPU_OP_NAME(_a28)(uae_u32 opcode) /* EOR */
  2356. {
  2357.     uae_u32 dstreg = opcode & 7;
  2358. {{    uae_s8 src = nextibyte();
  2359. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2360.     uae_s8 dst = get_byte(dsta);
  2361.     src ^= dst;
  2362.     VFLG = CFLG = 0;
  2363.     ZFLG = ((uae_s8)(src)) == 0;
  2364.     NFLG = ((uae_s8)(src)) < 0;
  2365.     put_byte(dsta,src);
  2366. }}}}
  2367. void REGPARAM2 CPU_OP_NAME(_a30)(uae_u32 opcode) /* EOR */
  2368. {
  2369.     uae_u32 dstreg = opcode & 7;
  2370. {{    uae_s8 src = nextibyte();
  2371. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2372. {    uae_s8 dst = get_byte(dsta);
  2373.     src ^= dst;
  2374.     VFLG = CFLG = 0;
  2375.     ZFLG = ((uae_s8)(src)) == 0;
  2376.     NFLG = ((uae_s8)(src)) < 0;
  2377.     put_byte(dsta,src);
  2378. }}}}}
  2379. void REGPARAM2 CPU_OP_NAME(_a38)(uae_u32 opcode) /* EOR */
  2380. {
  2381. {{    uae_s8 src = nextibyte();
  2382. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2383.     uae_s8 dst = get_byte(dsta);
  2384.     src ^= dst;
  2385.     VFLG = CFLG = 0;
  2386.     ZFLG = ((uae_s8)(src)) == 0;
  2387.     NFLG = ((uae_s8)(src)) < 0;
  2388.     put_byte(dsta,src);
  2389. }}}}
  2390. void REGPARAM2 CPU_OP_NAME(_a39)(uae_u32 opcode) /* EOR */
  2391. {
  2392. {{    uae_s8 src = nextibyte();
  2393. {    uaecptr dsta = nextilong();
  2394.     uae_s8 dst = get_byte(dsta);
  2395.     src ^= dst;
  2396.     VFLG = CFLG = 0;
  2397.     ZFLG = ((uae_s8)(src)) == 0;
  2398.     NFLG = ((uae_s8)(src)) < 0;
  2399.     put_byte(dsta,src);
  2400. }}}}
  2401. void REGPARAM2 CPU_OP_NAME(_a3c)(uae_u32 opcode) /* EORSR */
  2402. {
  2403. {    MakeSR();
  2404. {    uae_s16 src = nextiword();
  2405.     src &= 0xFF;
  2406.     regs.sr ^= src;
  2407.     MakeFromSR();
  2408. }}}
  2409. void REGPARAM2 CPU_OP_NAME(_a40)(uae_u32 opcode) /* EOR */
  2410. {
  2411.     uae_u32 dstreg = opcode & 7;
  2412. {{    uae_s16 src = nextiword();
  2413. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  2414.     src ^= dst;
  2415.     VFLG = CFLG = 0;
  2416.     ZFLG = ((uae_s16)(src)) == 0;
  2417.     NFLG = ((uae_s16)(src)) < 0;
  2418.     m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xffff) | ((src) & 0xffff);
  2419. }}}}
  2420. void REGPARAM2 CPU_OP_NAME(_a50)(uae_u32 opcode) /* EOR */
  2421. {
  2422.     uae_u32 dstreg = opcode & 7;
  2423. {{    uae_s16 src = nextiword();
  2424. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2425.     uae_s16 dst = get_word(dsta);
  2426.     src ^= dst;
  2427.     VFLG = CFLG = 0;
  2428.     ZFLG = ((uae_s16)(src)) == 0;
  2429.     NFLG = ((uae_s16)(src)) < 0;
  2430.     put_word(dsta,src);
  2431. }}}}
  2432. void REGPARAM2 CPU_OP_NAME(_a58)(uae_u32 opcode) /* EOR */
  2433. {
  2434.     uae_u32 dstreg = opcode & 7;
  2435. {{    uae_s16 src = nextiword();
  2436. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2437.     uae_s16 dst = get_word(dsta);
  2438. {    m68k_areg(regs, dstreg) += 2;
  2439.     src ^= dst;
  2440.     VFLG = CFLG = 0;
  2441.     ZFLG = ((uae_s16)(src)) == 0;
  2442.     NFLG = ((uae_s16)(src)) < 0;
  2443.     put_word(dsta,src);
  2444. }}}}}
  2445. void REGPARAM2 CPU_OP_NAME(_a60)(uae_u32 opcode) /* EOR */
  2446. {
  2447.     uae_u32 dstreg = opcode & 7;
  2448. {{    uae_s16 src = nextiword();
  2449. {    m68k_areg(regs, dstreg) -= 2;
  2450. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2451.     uae_s16 dst = get_word(dsta);
  2452.     src ^= dst;
  2453.     VFLG = CFLG = 0;
  2454.     ZFLG = ((uae_s16)(src)) == 0;
  2455.     NFLG = ((uae_s16)(src)) < 0;
  2456.     put_word(dsta,src);
  2457. }}}}}
  2458. void REGPARAM2 CPU_OP_NAME(_a68)(uae_u32 opcode) /* EOR */
  2459. {
  2460.     uae_u32 dstreg = opcode & 7;
  2461. {{    uae_s16 src = nextiword();
  2462. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2463.     uae_s16 dst = get_word(dsta);
  2464.     src ^= dst;
  2465.     VFLG = CFLG = 0;
  2466.     ZFLG = ((uae_s16)(src)) == 0;
  2467.     NFLG = ((uae_s16)(src)) < 0;
  2468.     put_word(dsta,src);
  2469. }}}}
  2470. void REGPARAM2 CPU_OP_NAME(_a70)(uae_u32 opcode) /* EOR */
  2471. {
  2472.     uae_u32 dstreg = opcode & 7;
  2473. {{    uae_s16 src = nextiword();
  2474. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2475. {    uae_s16 dst = get_word(dsta);
  2476.     src ^= dst;
  2477.     VFLG = CFLG = 0;
  2478.     ZFLG = ((uae_s16)(src)) == 0;
  2479.     NFLG = ((uae_s16)(src)) < 0;
  2480.     put_word(dsta,src);
  2481. }}}}}
  2482. void REGPARAM2 CPU_OP_NAME(_a78)(uae_u32 opcode) /* EOR */
  2483. {
  2484. {{    uae_s16 src = nextiword();
  2485. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2486.     uae_s16 dst = get_word(dsta);
  2487.     src ^= dst;
  2488.     VFLG = CFLG = 0;
  2489.     ZFLG = ((uae_s16)(src)) == 0;
  2490.     NFLG = ((uae_s16)(src)) < 0;
  2491.     put_word(dsta,src);
  2492. }}}}
  2493. void REGPARAM2 CPU_OP_NAME(_a79)(uae_u32 opcode) /* EOR */
  2494. {
  2495. {{    uae_s16 src = nextiword();
  2496. {    uaecptr dsta = nextilong();
  2497.     uae_s16 dst = get_word(dsta);
  2498.     src ^= dst;
  2499.     VFLG = CFLG = 0;
  2500.     ZFLG = ((uae_s16)(src)) == 0;
  2501.     NFLG = ((uae_s16)(src)) < 0;
  2502.     put_word(dsta,src);
  2503. }}}}
  2504. void REGPARAM2 CPU_OP_NAME(_a7c)(uae_u32 opcode) /* EORSR */
  2505. {
  2506. {if (!regs.s) { regs.pc_p -= 2; Exception(8,0); } else
  2507. {    MakeSR();
  2508. {    uae_s16 src = nextiword();
  2509.     regs.sr ^= src;
  2510.     MakeFromSR();
  2511. }}}}
  2512. void REGPARAM2 CPU_OP_NAME(_a80)(uae_u32 opcode) /* EOR */
  2513. {
  2514.     uae_u32 dstreg = opcode & 7;
  2515. {{    uae_s32 src = nextilong();
  2516. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  2517.     src ^= dst;
  2518.     VFLG = CFLG = 0;
  2519.     ZFLG = ((uae_s32)(src)) == 0;
  2520.     NFLG = ((uae_s32)(src)) < 0;
  2521.     m68k_dreg(regs, dstreg) = (src);
  2522. }}}}
  2523. void REGPARAM2 CPU_OP_NAME(_a90)(uae_u32 opcode) /* EOR */
  2524. {
  2525.     uae_u32 dstreg = opcode & 7;
  2526. {{    uae_s32 src = nextilong();
  2527. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2528.     uae_s32 dst = get_long(dsta);
  2529.     src ^= dst;
  2530.     VFLG = CFLG = 0;
  2531.     ZFLG = ((uae_s32)(src)) == 0;
  2532.     NFLG = ((uae_s32)(src)) < 0;
  2533.     put_long(dsta,src);
  2534. }}}}
  2535. void REGPARAM2 CPU_OP_NAME(_a98)(uae_u32 opcode) /* EOR */
  2536. {
  2537.     uae_u32 dstreg = opcode & 7;
  2538. {{    uae_s32 src = nextilong();
  2539. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2540.     uae_s32 dst = get_long(dsta);
  2541. {    m68k_areg(regs, dstreg) += 4;
  2542.     src ^= dst;
  2543.     VFLG = CFLG = 0;
  2544.     ZFLG = ((uae_s32)(src)) == 0;
  2545.     NFLG = ((uae_s32)(src)) < 0;
  2546.     put_long(dsta,src);
  2547. }}}}}
  2548. void REGPARAM2 CPU_OP_NAME(_aa0)(uae_u32 opcode) /* EOR */
  2549. {
  2550.     uae_u32 dstreg = opcode & 7;
  2551. {{    uae_s32 src = nextilong();
  2552. {    m68k_areg(regs, dstreg) -= 4;
  2553. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2554.     uae_s32 dst = get_long(dsta);
  2555.     src ^= dst;
  2556.     VFLG = CFLG = 0;
  2557.     ZFLG = ((uae_s32)(src)) == 0;
  2558.     NFLG = ((uae_s32)(src)) < 0;
  2559.     put_long(dsta,src);
  2560. }}}}}
  2561. void REGPARAM2 CPU_OP_NAME(_aa8)(uae_u32 opcode) /* EOR */
  2562. {
  2563.     uae_u32 dstreg = opcode & 7;
  2564. {{    uae_s32 src = nextilong();
  2565. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2566.     uae_s32 dst = get_long(dsta);
  2567.     src ^= dst;
  2568.     VFLG = CFLG = 0;
  2569.     ZFLG = ((uae_s32)(src)) == 0;
  2570.     NFLG = ((uae_s32)(src)) < 0;
  2571.     put_long(dsta,src);
  2572. }}}}
  2573. void REGPARAM2 CPU_OP_NAME(_ab0)(uae_u32 opcode) /* EOR */
  2574. {
  2575.     uae_u32 dstreg = opcode & 7;
  2576. {{    uae_s32 src = nextilong();
  2577. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2578. {    uae_s32 dst = get_long(dsta);
  2579.     src ^= dst;
  2580.     VFLG = CFLG = 0;
  2581.     ZFLG = ((uae_s32)(src)) == 0;
  2582.     NFLG = ((uae_s32)(src)) < 0;
  2583.     put_long(dsta,src);
  2584. }}}}}
  2585. void REGPARAM2 CPU_OP_NAME(_ab8)(uae_u32 opcode) /* EOR */
  2586. {
  2587. {{    uae_s32 src = nextilong();
  2588. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2589.     uae_s32 dst = get_long(dsta);
  2590.     src ^= dst;
  2591.     VFLG = CFLG = 0;
  2592.     ZFLG = ((uae_s32)(src)) == 0;
  2593.     NFLG = ((uae_s32)(src)) < 0;
  2594.     put_long(dsta,src);
  2595. }}}}
  2596. void REGPARAM2 CPU_OP_NAME(_ab9)(uae_u32 opcode) /* EOR */
  2597. {
  2598. {{    uae_s32 src = nextilong();
  2599. {    uaecptr dsta = nextilong();
  2600.     uae_s32 dst = get_long(dsta);
  2601.     src ^= dst;
  2602.     VFLG = CFLG = 0;
  2603.     ZFLG = ((uae_s32)(src)) == 0;
  2604.     NFLG = ((uae_s32)(src)) < 0;
  2605.     put_long(dsta,src);
  2606. }}}}
  2607. void REGPARAM2 CPU_OP_NAME(_c00)(uae_u32 opcode) /* CMP */
  2608. {
  2609.     uae_u32 dstreg = opcode & 7;
  2610. {{    uae_s8 src = nextibyte();
  2611. {    uae_s8 dst = m68k_dreg(regs, dstreg);
  2612. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2613. {    int flgs = ((uae_s8)(src)) < 0;
  2614.     int flgo = ((uae_s8)(dst)) < 0;
  2615.     int flgn = ((uae_s8)(newv)) < 0;
  2616.     ZFLG = ((uae_s8)(newv)) == 0;
  2617.     VFLG = (flgs != flgo) && (flgn != flgo);
  2618.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2619.     NFLG = flgn != 0;
  2620. }}}}}}}
  2621. void REGPARAM2 CPU_OP_NAME(_c10)(uae_u32 opcode) /* CMP */
  2622. {
  2623.     uae_u32 dstreg = opcode & 7;
  2624. {{    uae_s8 src = nextibyte();
  2625. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2626.     uae_s8 dst = get_byte(dsta);
  2627. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2628. {    int flgs = ((uae_s8)(src)) < 0;
  2629.     int flgo = ((uae_s8)(dst)) < 0;
  2630.     int flgn = ((uae_s8)(newv)) < 0;
  2631.     ZFLG = ((uae_s8)(newv)) == 0;
  2632.     VFLG = (flgs != flgo) && (flgn != flgo);
  2633.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2634.     NFLG = flgn != 0;
  2635. }}}}}}}
  2636. void REGPARAM2 CPU_OP_NAME(_c18)(uae_u32 opcode) /* CMP */
  2637. {
  2638.     uae_u32 dstreg = opcode & 7;
  2639. {{    uae_s8 src = nextibyte();
  2640. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2641.     uae_s8 dst = get_byte(dsta);
  2642. {    m68k_areg(regs, dstreg) += areg_byteinc[dstreg];
  2643. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2644. {    int flgs = ((uae_s8)(src)) < 0;
  2645.     int flgo = ((uae_s8)(dst)) < 0;
  2646.     int flgn = ((uae_s8)(newv)) < 0;
  2647.     ZFLG = ((uae_s8)(newv)) == 0;
  2648.     VFLG = (flgs != flgo) && (flgn != flgo);
  2649.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2650.     NFLG = flgn != 0;
  2651. }}}}}}}}
  2652. void REGPARAM2 CPU_OP_NAME(_c20)(uae_u32 opcode) /* CMP */
  2653. {
  2654.     uae_u32 dstreg = opcode & 7;
  2655. {{    uae_s8 src = nextibyte();
  2656. {    m68k_areg(regs, dstreg) -= areg_byteinc[dstreg];
  2657. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2658.     uae_s8 dst = get_byte(dsta);
  2659. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2660. {    int flgs = ((uae_s8)(src)) < 0;
  2661.     int flgo = ((uae_s8)(dst)) < 0;
  2662.     int flgn = ((uae_s8)(newv)) < 0;
  2663.     ZFLG = ((uae_s8)(newv)) == 0;
  2664.     VFLG = (flgs != flgo) && (flgn != flgo);
  2665.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2666.     NFLG = flgn != 0;
  2667. }}}}}}}}
  2668. void REGPARAM2 CPU_OP_NAME(_c28)(uae_u32 opcode) /* CMP */
  2669. {
  2670.     uae_u32 dstreg = opcode & 7;
  2671. {{    uae_s8 src = nextibyte();
  2672. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2673.     uae_s8 dst = get_byte(dsta);
  2674. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2675. {    int flgs = ((uae_s8)(src)) < 0;
  2676.     int flgo = ((uae_s8)(dst)) < 0;
  2677.     int flgn = ((uae_s8)(newv)) < 0;
  2678.     ZFLG = ((uae_s8)(newv)) == 0;
  2679.     VFLG = (flgs != flgo) && (flgn != flgo);
  2680.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2681.     NFLG = flgn != 0;
  2682. }}}}}}}
  2683. void REGPARAM2 CPU_OP_NAME(_c30)(uae_u32 opcode) /* CMP */
  2684. {
  2685.     uae_u32 dstreg = opcode & 7;
  2686. {{    uae_s8 src = nextibyte();
  2687. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2688. {    uae_s8 dst = get_byte(dsta);
  2689. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2690. {    int flgs = ((uae_s8)(src)) < 0;
  2691.     int flgo = ((uae_s8)(dst)) < 0;
  2692.     int flgn = ((uae_s8)(newv)) < 0;
  2693.     ZFLG = ((uae_s8)(newv)) == 0;
  2694.     VFLG = (flgs != flgo) && (flgn != flgo);
  2695.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2696.     NFLG = flgn != 0;
  2697. }}}}}}}}
  2698. void REGPARAM2 CPU_OP_NAME(_c38)(uae_u32 opcode) /* CMP */
  2699. {
  2700. {{    uae_s8 src = nextibyte();
  2701. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2702.     uae_s8 dst = get_byte(dsta);
  2703. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2704. {    int flgs = ((uae_s8)(src)) < 0;
  2705.     int flgo = ((uae_s8)(dst)) < 0;
  2706.     int flgn = ((uae_s8)(newv)) < 0;
  2707.     ZFLG = ((uae_s8)(newv)) == 0;
  2708.     VFLG = (flgs != flgo) && (flgn != flgo);
  2709.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2710.     NFLG = flgn != 0;
  2711. }}}}}}}
  2712. void REGPARAM2 CPU_OP_NAME(_c39)(uae_u32 opcode) /* CMP */
  2713. {
  2714. {{    uae_s8 src = nextibyte();
  2715. {    uaecptr dsta = nextilong();
  2716.     uae_s8 dst = get_byte(dsta);
  2717. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2718. {    int flgs = ((uae_s8)(src)) < 0;
  2719.     int flgo = ((uae_s8)(dst)) < 0;
  2720.     int flgn = ((uae_s8)(newv)) < 0;
  2721.     ZFLG = ((uae_s8)(newv)) == 0;
  2722.     VFLG = (flgs != flgo) && (flgn != flgo);
  2723.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2724.     NFLG = flgn != 0;
  2725. }}}}}}}
  2726. void REGPARAM2 CPU_OP_NAME(_c3a)(uae_u32 opcode) /* CMP */
  2727. {
  2728.     uae_u32 dstreg = 2;
  2729. {{    uae_s8 src = nextibyte();
  2730. {    uaecptr dsta = m68k_getpc();
  2731.     dsta += (uae_s32)(uae_s16)nextiword();
  2732. {    uae_s8 dst = get_byte(dsta);
  2733. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2734. {    int flgs = ((uae_s8)(src)) < 0;
  2735.     int flgo = ((uae_s8)(dst)) < 0;
  2736.     int flgn = ((uae_s8)(newv)) < 0;
  2737.     ZFLG = ((uae_s8)(newv)) == 0;
  2738.     VFLG = (flgs != flgo) && (flgn != flgo);
  2739.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2740.     NFLG = flgn != 0;
  2741. }}}}}}}}
  2742. void REGPARAM2 CPU_OP_NAME(_c3b)(uae_u32 opcode) /* CMP */
  2743. {
  2744.     uae_u32 dstreg = 3;
  2745. {{    uae_s8 src = nextibyte();
  2746. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  2747. {    uae_s8 dst = get_byte(dsta);
  2748. {{uae_u32 newv = ((uae_s8)(dst)) - ((uae_s8)(src));
  2749. {    int flgs = ((uae_s8)(src)) < 0;
  2750.     int flgo = ((uae_s8)(dst)) < 0;
  2751.     int flgn = ((uae_s8)(newv)) < 0;
  2752.     ZFLG = ((uae_s8)(newv)) == 0;
  2753.     VFLG = (flgs != flgo) && (flgn != flgo);
  2754.     CFLG = ((uae_u8)(src)) > ((uae_u8)(dst));
  2755.     NFLG = flgn != 0;
  2756. }}}}}}}}
  2757. void REGPARAM2 CPU_OP_NAME(_c40)(uae_u32 opcode) /* CMP */
  2758. {
  2759.     uae_u32 dstreg = opcode & 7;
  2760. {{    uae_s16 src = nextiword();
  2761. {    uae_s16 dst = m68k_dreg(regs, dstreg);
  2762. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2763. {    int flgs = ((uae_s16)(src)) < 0;
  2764.     int flgo = ((uae_s16)(dst)) < 0;
  2765.     int flgn = ((uae_s16)(newv)) < 0;
  2766.     ZFLG = ((uae_s16)(newv)) == 0;
  2767.     VFLG = (flgs != flgo) && (flgn != flgo);
  2768.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2769.     NFLG = flgn != 0;
  2770. }}}}}}}
  2771. void REGPARAM2 CPU_OP_NAME(_c50)(uae_u32 opcode) /* CMP */
  2772. {
  2773.     uae_u32 dstreg = opcode & 7;
  2774. {{    uae_s16 src = nextiword();
  2775. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2776.     uae_s16 dst = get_word(dsta);
  2777. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2778. {    int flgs = ((uae_s16)(src)) < 0;
  2779.     int flgo = ((uae_s16)(dst)) < 0;
  2780.     int flgn = ((uae_s16)(newv)) < 0;
  2781.     ZFLG = ((uae_s16)(newv)) == 0;
  2782.     VFLG = (flgs != flgo) && (flgn != flgo);
  2783.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2784.     NFLG = flgn != 0;
  2785. }}}}}}}
  2786. void REGPARAM2 CPU_OP_NAME(_c58)(uae_u32 opcode) /* CMP */
  2787. {
  2788.     uae_u32 dstreg = opcode & 7;
  2789. {{    uae_s16 src = nextiword();
  2790. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2791.     uae_s16 dst = get_word(dsta);
  2792. {    m68k_areg(regs, dstreg) += 2;
  2793. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2794. {    int flgs = ((uae_s16)(src)) < 0;
  2795.     int flgo = ((uae_s16)(dst)) < 0;
  2796.     int flgn = ((uae_s16)(newv)) < 0;
  2797.     ZFLG = ((uae_s16)(newv)) == 0;
  2798.     VFLG = (flgs != flgo) && (flgn != flgo);
  2799.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2800.     NFLG = flgn != 0;
  2801. }}}}}}}}
  2802. void REGPARAM2 CPU_OP_NAME(_c60)(uae_u32 opcode) /* CMP */
  2803. {
  2804.     uae_u32 dstreg = opcode & 7;
  2805. {{    uae_s16 src = nextiword();
  2806. {    m68k_areg(regs, dstreg) -= 2;
  2807. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2808.     uae_s16 dst = get_word(dsta);
  2809. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2810. {    int flgs = ((uae_s16)(src)) < 0;
  2811.     int flgo = ((uae_s16)(dst)) < 0;
  2812.     int flgn = ((uae_s16)(newv)) < 0;
  2813.     ZFLG = ((uae_s16)(newv)) == 0;
  2814.     VFLG = (flgs != flgo) && (flgn != flgo);
  2815.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2816.     NFLG = flgn != 0;
  2817. }}}}}}}}
  2818. void REGPARAM2 CPU_OP_NAME(_c68)(uae_u32 opcode) /* CMP */
  2819. {
  2820.     uae_u32 dstreg = opcode & 7;
  2821. {{    uae_s16 src = nextiword();
  2822. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2823.     uae_s16 dst = get_word(dsta);
  2824. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2825. {    int flgs = ((uae_s16)(src)) < 0;
  2826.     int flgo = ((uae_s16)(dst)) < 0;
  2827.     int flgn = ((uae_s16)(newv)) < 0;
  2828.     ZFLG = ((uae_s16)(newv)) == 0;
  2829.     VFLG = (flgs != flgo) && (flgn != flgo);
  2830.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2831.     NFLG = flgn != 0;
  2832. }}}}}}}
  2833. void REGPARAM2 CPU_OP_NAME(_c70)(uae_u32 opcode) /* CMP */
  2834. {
  2835.     uae_u32 dstreg = opcode & 7;
  2836. {{    uae_s16 src = nextiword();
  2837. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2838. {    uae_s16 dst = get_word(dsta);
  2839. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2840. {    int flgs = ((uae_s16)(src)) < 0;
  2841.     int flgo = ((uae_s16)(dst)) < 0;
  2842.     int flgn = ((uae_s16)(newv)) < 0;
  2843.     ZFLG = ((uae_s16)(newv)) == 0;
  2844.     VFLG = (flgs != flgo) && (flgn != flgo);
  2845.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2846.     NFLG = flgn != 0;
  2847. }}}}}}}}
  2848. void REGPARAM2 CPU_OP_NAME(_c78)(uae_u32 opcode) /* CMP */
  2849. {
  2850. {{    uae_s16 src = nextiword();
  2851. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  2852.     uae_s16 dst = get_word(dsta);
  2853. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2854. {    int flgs = ((uae_s16)(src)) < 0;
  2855.     int flgo = ((uae_s16)(dst)) < 0;
  2856.     int flgn = ((uae_s16)(newv)) < 0;
  2857.     ZFLG = ((uae_s16)(newv)) == 0;
  2858.     VFLG = (flgs != flgo) && (flgn != flgo);
  2859.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2860.     NFLG = flgn != 0;
  2861. }}}}}}}
  2862. void REGPARAM2 CPU_OP_NAME(_c79)(uae_u32 opcode) /* CMP */
  2863. {
  2864. {{    uae_s16 src = nextiword();
  2865. {    uaecptr dsta = nextilong();
  2866.     uae_s16 dst = get_word(dsta);
  2867. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2868. {    int flgs = ((uae_s16)(src)) < 0;
  2869.     int flgo = ((uae_s16)(dst)) < 0;
  2870.     int flgn = ((uae_s16)(newv)) < 0;
  2871.     ZFLG = ((uae_s16)(newv)) == 0;
  2872.     VFLG = (flgs != flgo) && (flgn != flgo);
  2873.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2874.     NFLG = flgn != 0;
  2875. }}}}}}}
  2876. void REGPARAM2 CPU_OP_NAME(_c7a)(uae_u32 opcode) /* CMP */
  2877. {
  2878.     uae_u32 dstreg = 2;
  2879. {{    uae_s16 src = nextiword();
  2880. {    uaecptr dsta = m68k_getpc();
  2881.     dsta += (uae_s32)(uae_s16)nextiword();
  2882. {    uae_s16 dst = get_word(dsta);
  2883. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2884. {    int flgs = ((uae_s16)(src)) < 0;
  2885.     int flgo = ((uae_s16)(dst)) < 0;
  2886.     int flgn = ((uae_s16)(newv)) < 0;
  2887.     ZFLG = ((uae_s16)(newv)) == 0;
  2888.     VFLG = (flgs != flgo) && (flgn != flgo);
  2889.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2890.     NFLG = flgn != 0;
  2891. }}}}}}}}
  2892. void REGPARAM2 CPU_OP_NAME(_c7b)(uae_u32 opcode) /* CMP */
  2893. {
  2894.     uae_u32 dstreg = 3;
  2895. {{    uae_s16 src = nextiword();
  2896. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  2897. {    uae_s16 dst = get_word(dsta);
  2898. {{uae_u32 newv = ((uae_s16)(dst)) - ((uae_s16)(src));
  2899. {    int flgs = ((uae_s16)(src)) < 0;
  2900.     int flgo = ((uae_s16)(dst)) < 0;
  2901.     int flgn = ((uae_s16)(newv)) < 0;
  2902.     ZFLG = ((uae_s16)(newv)) == 0;
  2903.     VFLG = (flgs != flgo) && (flgn != flgo);
  2904.     CFLG = ((uae_u16)(src)) > ((uae_u16)(dst));
  2905.     NFLG = flgn != 0;
  2906. }}}}}}}}
  2907. void REGPARAM2 CPU_OP_NAME(_c80)(uae_u32 opcode) /* CMP */
  2908. {
  2909.     uae_u32 dstreg = opcode & 7;
  2910. {{    uae_s32 src = nextilong();
  2911. {    uae_s32 dst = m68k_dreg(regs, dstreg);
  2912. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2913. {    int flgs = ((uae_s32)(src)) < 0;
  2914.     int flgo = ((uae_s32)(dst)) < 0;
  2915.     int flgn = ((uae_s32)(newv)) < 0;
  2916.     ZFLG = ((uae_s32)(newv)) == 0;
  2917.     VFLG = (flgs != flgo) && (flgn != flgo);
  2918.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2919.     NFLG = flgn != 0;
  2920. }}}}}}}
  2921. void REGPARAM2 CPU_OP_NAME(_c90)(uae_u32 opcode) /* CMP */
  2922. {
  2923.     uae_u32 dstreg = opcode & 7;
  2924. {{    uae_s32 src = nextilong();
  2925. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2926.     uae_s32 dst = get_long(dsta);
  2927. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2928. {    int flgs = ((uae_s32)(src)) < 0;
  2929.     int flgo = ((uae_s32)(dst)) < 0;
  2930.     int flgn = ((uae_s32)(newv)) < 0;
  2931.     ZFLG = ((uae_s32)(newv)) == 0;
  2932.     VFLG = (flgs != flgo) && (flgn != flgo);
  2933.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2934.     NFLG = flgn != 0;
  2935. }}}}}}}
  2936. void REGPARAM2 CPU_OP_NAME(_c98)(uae_u32 opcode) /* CMP */
  2937. {
  2938.     uae_u32 dstreg = opcode & 7;
  2939. {{    uae_s32 src = nextilong();
  2940. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2941.     uae_s32 dst = get_long(dsta);
  2942. {    m68k_areg(regs, dstreg) += 4;
  2943. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2944. {    int flgs = ((uae_s32)(src)) < 0;
  2945.     int flgo = ((uae_s32)(dst)) < 0;
  2946.     int flgn = ((uae_s32)(newv)) < 0;
  2947.     ZFLG = ((uae_s32)(newv)) == 0;
  2948.     VFLG = (flgs != flgo) && (flgn != flgo);
  2949.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2950.     NFLG = flgn != 0;
  2951. }}}}}}}}
  2952. void REGPARAM2 CPU_OP_NAME(_ca0)(uae_u32 opcode) /* CMP */
  2953. {
  2954.     uae_u32 dstreg = opcode & 7;
  2955. {{    uae_s32 src = nextilong();
  2956. {    m68k_areg(regs, dstreg) -= 4;
  2957. {    uaecptr dsta = m68k_areg(regs, dstreg);
  2958.     uae_s32 dst = get_long(dsta);
  2959. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2960. {    int flgs = ((uae_s32)(src)) < 0;
  2961.     int flgo = ((uae_s32)(dst)) < 0;
  2962.     int flgn = ((uae_s32)(newv)) < 0;
  2963.     ZFLG = ((uae_s32)(newv)) == 0;
  2964.     VFLG = (flgs != flgo) && (flgn != flgo);
  2965.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2966.     NFLG = flgn != 0;
  2967. }}}}}}}}
  2968. void REGPARAM2 CPU_OP_NAME(_ca8)(uae_u32 opcode) /* CMP */
  2969. {
  2970.     uae_u32 dstreg = opcode & 7;
  2971. {{    uae_s32 src = nextilong();
  2972. {    uaecptr dsta = m68k_areg(regs, dstreg) + (uae_s32)(uae_s16)nextiword();
  2973.     uae_s32 dst = get_long(dsta);
  2974. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2975. {    int flgs = ((uae_s32)(src)) < 0;
  2976.     int flgo = ((uae_s32)(dst)) < 0;
  2977.     int flgn = ((uae_s32)(newv)) < 0;
  2978.     ZFLG = ((uae_s32)(newv)) == 0;
  2979.     VFLG = (flgs != flgo) && (flgn != flgo);
  2980.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2981.     NFLG = flgn != 0;
  2982. }}}}}}}
  2983. void REGPARAM2 CPU_OP_NAME(_cb0)(uae_u32 opcode) /* CMP */
  2984. {
  2985.     uae_u32 dstreg = opcode & 7;
  2986. {{    uae_s32 src = nextilong();
  2987. {    uaecptr dsta = get_disp_ea(m68k_areg(regs, dstreg));
  2988. {    uae_s32 dst = get_long(dsta);
  2989. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  2990. {    int flgs = ((uae_s32)(src)) < 0;
  2991.     int flgo = ((uae_s32)(dst)) < 0;
  2992.     int flgn = ((uae_s32)(newv)) < 0;
  2993.     ZFLG = ((uae_s32)(newv)) == 0;
  2994.     VFLG = (flgs != flgo) && (flgn != flgo);
  2995.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  2996.     NFLG = flgn != 0;
  2997. }}}}}}}}
  2998. void REGPARAM2 CPU_OP_NAME(_cb8)(uae_u32 opcode) /* CMP */
  2999. {
  3000. {{    uae_s32 src = nextilong();
  3001. {    uaecptr dsta = (uae_s32)(uae_s16)nextiword();
  3002.     uae_s32 dst = get_long(dsta);
  3003. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  3004. {    int flgs = ((uae_s32)(src)) < 0;
  3005.     int flgo = ((uae_s32)(dst)) < 0;
  3006.     int flgn = ((uae_s32)(newv)) < 0;
  3007.     ZFLG = ((uae_s32)(newv)) == 0;
  3008.     VFLG = (flgs != flgo) && (flgn != flgo);
  3009.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  3010.     NFLG = flgn != 0;
  3011. }}}}}}}
  3012. void REGPARAM2 CPU_OP_NAME(_cb9)(uae_u32 opcode) /* CMP */
  3013. {
  3014. {{    uae_s32 src = nextilong();
  3015. {    uaecptr dsta = nextilong();
  3016.     uae_s32 dst = get_long(dsta);
  3017. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  3018. {    int flgs = ((uae_s32)(src)) < 0;
  3019.     int flgo = ((uae_s32)(dst)) < 0;
  3020.     int flgn = ((uae_s32)(newv)) < 0;
  3021.     ZFLG = ((uae_s32)(newv)) == 0;
  3022.     VFLG = (flgs != flgo) && (flgn != flgo);
  3023.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  3024.     NFLG = flgn != 0;
  3025. }}}}}}}
  3026. void REGPARAM2 CPU_OP_NAME(_cba)(uae_u32 opcode) /* CMP */
  3027. {
  3028.     uae_u32 dstreg = 2;
  3029. {{    uae_s32 src = nextilong();
  3030. {    uaecptr dsta = m68k_getpc();
  3031.     dsta += (uae_s32)(uae_s16)nextiword();
  3032. {    uae_s32 dst = get_long(dsta);
  3033. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  3034. {    int flgs = ((uae_s32)(src)) < 0;
  3035.     int flgo = ((uae_s32)(dst)) < 0;
  3036.     int flgn = ((uae_s32)(newv)) < 0;
  3037.     ZFLG = ((uae_s32)(newv)) == 0;
  3038.     VFLG = (flgs != flgo) && (flgn != flgo);
  3039.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  3040.     NFLG = flgn != 0;
  3041. }}}}}}}}
  3042. void REGPARAM2 CPU_OP_NAME(_cbb)(uae_u32 opcode) /* CMP */
  3043. {
  3044.     uae_u32 dstreg = 3;
  3045. {{    uae_s32 src = nextilong();
  3046. {    uaecptr dsta = get_disp_ea(m68k_getpc());
  3047. {    uae_s32 dst = get_long(dsta);
  3048. {{uae_u32 newv = ((uae_s32)(dst)) - ((uae_s32)(src));
  3049. {    int flgs = ((uae_s32)(src)) < 0;
  3050.     int flgo = ((uae_s32)(dst)) < 0;
  3051.     int flgn = ((uae_s32)(newv)) < 0;
  3052.     ZFLG = ((uae_s32)(newv)) == 0;
  3053.     VFLG = (flgs != flgo) && (flgn != flgo);
  3054.     CFLG = ((uae_u32)(src)) > ((uae_u32)(dst));
  3055.     NFLG = flgn != 0;
  3056. }}}}}}}}
  3057. #endif
  3058.